Menu

#22 Segmentation fault with 1.50

None
closed-fixed
nobody
None
5
2015-02-11
2015-02-07
No

Just built 1.50 for both OpenSUSE 13.2 and Fedora 21, and on each system xdiskusage runs fine unless you specify a directory on the command line, like:

xdiskusage /boot

On each of the mentioned systems I get a Segmentation fault, this is the openSUSE 13.2 backtrace:

Program received signal SIGSEGV, Segmentation fault.
0x0804b440 in reload_cb(Fl_Button*, void*) ()
(gdb) bt
#0  0x0804b440 in reload_cb(Fl_Button*, void*) ()
#1  0x0804cf50 in OutputWindow::make(char const*, Disk*) ()
#2  0x08049eda in main ()

Discussion

  • John Beranek

    John Beranek - 2015-02-07

    More usefully:

    (gdb) bt
    #0  0x0804ee84 in Fl_Browser_::textsize (this=0x0)
        at /usr/include/FL/Fl_Browser_.H:282
    #1  0x0804b51b in reload_cb () at xdiskusage.C:162
    #2  0x0804becf in OutputWindow::make (path=0xbffff1a1 "/boot", disk=0x0)
        at xdiskusage.C:473
    #3  0x0804ba08 in main (argc=2, argv=0xbfffeed4) at xdiskusage.C:308
    (gdb) up
    #1  0x0804b51b in reload_cb () at xdiskusage.C:162
    162         int n = disk_browser->textsize();
    (gdb) print disk_browser
    $1 = (Fl_Browser *) 0x0
    
     
  • John Beranek

    John Beranek - 2015-02-08

    Fixed with this probably sub-optimally placed fix:

    --- xdiskusage-1.50/xdiskusage.C    2014-11-20 23:15:36.000000000 +0000
    +++ xdiskusage-1.50-fixed/xdiskusage.C  2015-02-08 00:04:46.993694650 +0000
    @@ -469,6 +469,9 @@
           }
           // See if the path we were given is really a mountpoint, in which case
           // we can figure out freespace.
    
    +      if (!disk_browser) {
    +        make_diskchooser();
    +      }
           reload_cb(0,0);
           for (Disk* d=firstdisk; d; d=d->next) {
             if(strcmp(d->mount, path) == 0) {
    
     
  • Bill Spitzak

    Bill Spitzak - 2015-02-09
    • status: open --> closed-fixed
    • Group: -->
     
  • Bill Spitzak

    Bill Spitzak - 2015-02-09

    Fixed in version 1.51

     

Log in to post a comment.

MongoDB Logo MongoDB