Bug 84925 - FILEOPEN: crash: "bad rational: zero denominator"
Summary: FILEOPEN: crash: "bad rational: zero denominator"
Status: VERIFIED FIXED
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Draw (show other bugs)
Version:
(earliest affected)
4.4.0.0.alpha0+ Master
Hardware: x86-64 (AMD64) Linux (All)
: high major
Assignee: David Tardon
URL:
Whiteboard:
Keywords: bibisected, regression
Depends on:
Blocks:
 
Reported: 2014-10-11 23:39 UTC by Terrence Enger
Modified: 2015-12-15 11:03 UTC (History)
2 users (show)

See Also:
Crash report or crash signature:


Attachments
gdb on the core file left by exception (7.78 KB, text/plain)
2014-10-11 23:48 UTC, Terrence Enger
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Terrence Enger 2014-10-11 23:39:09 UTC
I stumbled across this while trying to bibisect bug 84904
"Distribution icons look distorted".  In the daily dbgutil version
2014-10-10, the program raises an assertion:

    terminate called after throwing an instance of 'boost::bad_rational'
      what():  bad rational: zero denominator
    Application Error

    Fatal exception: Signal 6

In the version 2014-10-11, the program presents the message in a
msgbox and then exits.


STR

(1) Download file tux-distribution.odg attached to bug 51876
    <https://bugs.freedesktop.org/attachment.cgi?id=51876>.

(2) Open the file from the command line.  Program raises assertion or
    displays msgbox.
 

Working in the daily dbgutil bibisect repository, I see from `git bisect good`:

    785246df606966e83402647cc4923a4ea105a157 is the first bad commit
    commit 785246df606966e83402647cc4923a4ea105a157
    Author: Miklos Vajna <vmiklos@collabora.co.uk>
    Date:   Fri Oct 10 09:01:45 2014 +0200

        2014-10-10

    :100644 100644 4f660ff0796762d84ea97a70133d10090979f6cb 0663be04814dc27ba92b5f9019304280a89c9035 M	build-info.txt
    :040000 040000 2524afaef63acb3e2b9144cfb2ff9963923c0517 00916673606efdbc667651de5fb1e2617991a9fd M	opt

and from `git bisect log`:

    # bad: [f74c7588b7c904a42918d844d67a58ca89430dec] 2014-10-11
    # good: [b3130c846de5cf1b4be48b48dfc780bb369549fa] 2014-05-21
    git bisect start 'origin/master' 'oldest'
    # good: [10c0baf70759700c275cdd8c6fadf4919800714d] 2014-08-01
    git bisect good 10c0baf70759700c275cdd8c6fadf4919800714d
    # good: [bc8fe1433f6f3c946571d2c65d2d58553efbd9c6] 2014-09-05
    git bisect good bc8fe1433f6f3c946571d2c65d2d58553efbd9c6
    # good: [df3b0ca62028d5327e209d1aeb7dd4895be8b24f] 2014-09-23
    git bisect good df3b0ca62028d5327e209d1aeb7dd4895be8b24f
    # skip: [551ca0d91e916e46647d27ab110e3bd8ffd23a73] 2014-10-02
    git bisect skip 551ca0d91e916e46647d27ab110e3bd8ffd23a73
    # good: [89d418aefe6115554b888c334ec405487baf9cda] 2014-09-26
    git bisect good 89d418aefe6115554b888c334ec405487baf9cda
    # skip: [349dac014f57df33b02dd0553a674bf83039736b] 2014-10-03
    git bisect skip 349dac014f57df33b02dd0553a674bf83039736b
    # good: [ad81c51cf7146ff34cb5a964236160022425b540] 2014-10-08
    git bisect good ad81c51cf7146ff34cb5a964236160022425b540
    # bad: [785246df606966e83402647cc4923a4ea105a157] 2014-10-10
    git bisect bad 785246df606966e83402647cc4923a4ea105a157
    # good: [f4caa611c55114b6fb18422851535b4d921b25e4] 2014-10-09
    git bisect good f4caa611c55114b6fb18422851535b4d921b25e4
    # first bad commit: [785246df606966e83402647cc4923a4ea105a157] 2014-10-10
Comment 1 Terrence Enger 2014-10-11 23:48:31 UTC
Created attachment 107729 [details]
gdb on the core file left by exception

Obviously, I meant that version of 2014-10-10 throws an exception.
Comment 2 Julien Nabet 2014-10-12 08:48:10 UTC
On pc Debian x86-64 with master sources updated yesterday, I could reproduce this.
Comment 3 Julien Nabet 2014-10-12 08:50:26 UTC
I increase a bit the importance since it's a regression + prevent from opening a file.

David: any idea how to pinpoint this one? (I didn't succeed in retrieving a backtrace since after the popup, LO stops and doesn't segfault).
Comment 4 Terrence Enger 2014-10-12 18:11:07 UTC
I have just started a build.  I should be able to supply a backtrace
in about 24 hours.
Comment 5 Terrence Enger 2014-10-14 15:53:33 UTC
The problem is gone in daily dbgutil bibisect repo version 2014-10-14.
Setting bug status VERIFIED.

I think that the relevant commit is "boost::rational throws if 0 is
passed as denominator",
<http://cgit.freedesktop.org/libreoffice/core/commit/?id=1c8695ecf65174298ebd9edb5b0289db07af98ca>.
Comment 6 Robinson Tryon (qubit) 2015-12-15 11:03:33 UTC Comment hidden (obsolete)