itop crashed with SIGSEGV in __libc_start_main()

Bug #188897 reported by Emmet Hikory
10
Affects Status Importance Assigned to Milestone
itop (Debian)
Fix Released
Unknown
itop (Ubuntu)
Fix Released
Low
Siegfried Gevatter

Bug Description

Binary package hint: itop

This crash doesn't happen on i386, and doesn't happen from a local rebuild from sbuild (hence the most recent upload). There's something about the way that the buildds compile this program for amd64 (and possibly other architectures) that causes the crash.

Unfortunately, the stack trace doesn't tell me anything.

ProblemType: Crash
Architecture: amd64
CrashCounter: 1
Date: Sun Feb 3 21:58:33 2008
Dependencies:
 libgcc1 1:4.2.3-1ubuntu1
 gcc-4.2-base 4.2.3-1ubuntu1
 libc6 2.7-5ubuntu2
DistroRelease: Ubuntu 8.04
ExecutablePath: /usr/bin/itop
NonfreeKernelModules: nvidia
Package: itop 0.1-1build1
PackageArchitecture: amd64
ProcCmdline: itop
ProcCwd: /home/persia/src/scratch/revu
ProcEnviron:
 SHELL=/bin/bash
 PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/bin/X11:/usr/games
 LANG=en_US.UTF-8
Signal: 11
SourcePackage: itop
StacktraceTop:
 ?? ()
 ?? ()
 __libc_start_main () from /lib/libc.so.6
 ?? ()
 ?? ()
Title: itop crashed with SIGSEGV in __libc_start_main()
Uname: Linux frigga 2.6.24-5-generic #1 SMP Thu Jan 24 19:29:14 UTC 2008 x86_64 GNU/Linux
UserGroups: adm admin audio cdrom data-dev dialout dip floppy lpadmin plugdev pulse-rt sambashare scanner src sudo vboxusers video

Related branches

Revision history for this message
Emmet Hikory (persia) wrote :
Changed in itop:
importance: Undecided → Low
Revision history for this message
Apport retracing service (apport) wrote : Symbolic stack trace

StacktraceTop:?? ()
?? ()
__libc_start_main () from /lib/libc.so.6
?? ()
?? ()

Revision history for this message
Apport retracing service (apport) wrote : Symbolic threaded stack trace
Revision history for this message
Apport retracing service (apport) wrote : Stack trace with source code
Revision history for this message
Emmet Hikory (persia) wrote :

Just as a note, running locally against gdb doesn't produce a useful stacktrace either (even with local -dbgsym), and I can't reproduce the crash with a local recompile.

Revision history for this message
Albert Damen (albrt) wrote :

I can confirm the bug with itop 0.1-1build1. A rebuild in pbuilder did not fix it. Itop crashed frequently at start-up.
My system is also an amd64.
As itop did not create a proper stacktrace, I rebuilt itop with:
- strip removed from src/Makefile
- option -ggdb added as option to gcc in src/Makefile
- pkg-create-dbgsym added as build-dependency

Running itop from the resulting itop and itop-dbgsym packages gave a proper backtrace (attached).
Analysis shows cur_no = 503. However, cur_no is used as index for an array (interrupts) with size 256 (defined as MAX_INTS in src/config.h), so the array index is out of bounds.
Rebuilding itop with MAX_INTS=1024 instead of 256 solves the issue. As cur_no gets set from the first 3 characters on each string read from /proc/interrupts, it can have maximum 3 digits. Therefore MAX_INTS=1024 should be a safe value to use.

Changed in itop:
assignee: nobody → albrt
status: New → In Progress
Revision history for this message
Albert Damen (albrt) wrote :

The attached debdiff increases MAX_INTS from 256 to 1024. The package builds in pbuilder, installs and runs fine.

Changed in itop:
assignee: albrt → nobody
status: In Progress → Confirmed
Changed in itop:
assignee: nobody → rainct
status: Confirmed → In Progress
Revision history for this message
Siegfried Gevatter (rainct) wrote :

Uploaded with additional changes. Thanks for your debdiff!

Changed in itop:
status: In Progress → Fix Committed
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package itop - 0.1-1ubuntu1

---------------
itop (0.1-1ubuntu1) hardy; urgency=low

  [ Siegfried-Angel Gevatter Pujals (RainCT) ]
  * Fix debian/watch (Closes: #450026)
  * Remove debian/docs; TODO and README have no interesting content.

  [ Albert Damen ]
  * src/config.h: increase MAX_INTS from 256 to 1024, to really
    fix the segfault (LP: #188897)
  * Modify Maintainer value to match the DebianMaintainerField
    specification.

 -- Albert Damen <email address hidden> Mon, 04 Feb 2008 20:25:52 +0100

Changed in itop:
status: Fix Committed → Fix Released
Changed in itop:
status: Unknown → New
Changed in itop:
status: New → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.