Buffer overflow when opening the "Tools" popup

Bug #313931 reported by Andrew Paprocki
38
This bug affects 7 people
Affects Status Importance Assigned to Milestone
Seq24
New
Undecided
Unassigned
seq24 (Ubuntu)
Fix Released
Undecided
Unassigned

Bug Description

This is in 0.9.0:

*** buffer overflow detected ***: /opt/seq24-0.9.0/bin/seq24 terminated
======= Backtrace: =========
/lib/libc.so.6(__fortify_fail+0x37)[0x7f3344139887]
/lib/libc.so.6[0x7f3344137750]
/lib/libc.so.6[0x7f3344136ae9]
/lib/libc.so.6(_IO_default_xsputn+0x96)[0x7f33440b2116]
/lib/libc.so.6(_IO_vfprintf+0x63b)[0x7f3344081cbb]
/lib/libc.so.6(__vsprintf_chk+0x9d)[0x7f3344136b8d]
/lib/libc.so.6(__sprintf_chk+0x80)[0x7f3344136ad0]
/opt/seq24-0.9.0/bin/seq24[0x44648f]
/usr/lib/libglibmm-2.4.so.1(_ZN4Glib17SignalProxyNormal19slot0_void_callbackEP8_GObjectPv+0x32)[0x7f3347af7202]
...

seqedit.cpp:587

The problem is that the 'num' buffer is too small to fit the widest string: "+12 [VIII]". In general this code should be using snprintf instead of sprintf.

Revision history for this message
Andrew Paprocki (andrew-ishiboo) wrote :
Revision history for this message
Martin Tarenskeen (m-tarenskeen) wrote :

I don't know much about C programming and if I'm experiencing this same bug, but I can confirm that seq24 crashes when I click on the tools button.

Revision history for this message
Nareto (rennabh) wrote :

I can confirm it too on my system

Revision history for this message
lieven moors (lievenmoors) wrote :

I want to confirm this bug and add another backtrace

Revision history for this message
nickleus (nick-humphrey) wrote :

happens also to me on amd64 karmic. i right click on an empty square in the main window > New
then in the Edit window i push the hammer/tools button and the program immediately crashes/shuts down.

Revision history for this message
Michael Higgins (col) wrote :

Yes, this happens for me as well. Makes me wonder what is under that 'tools' menu.

Is there any chance this can be fixed?

Revision history for this message
Sebastien Alaiwan (ace17) wrote :

The trunk version does not use sprintf anymore, only snprintfs, and I cannot reproduce this bug on the trunk version.
Has anybody experienced this bug with any version newer than 0.9.0 ?

Revision history for this message
Michael Higgins (col) wrote :

Just checked out the trunk, yes it is fixed. Can we get a new tarball pushed out to distros, please? ;-)

Revision history for this message
nickleus (nick-humphrey) wrote :

according to https://launchpad.net/seq24 trunk is 0.9.0, which is the current version in karmic, unless that launchpad page is out of date??

Revision history for this message
Caldrac (caldrac) wrote :

I can confirm, that the bug is fixed for Ubuntu Studio 9.10 with the bleeding edge trunk version

@nickleus:
Follow this guide:
http://seq24.wikispaces.com/Compiling+Seq24+on+Ubuntu+Hardy+%288.04%29

If you experience this problem with "$autoreconf -fi":
   aclocal:configure.in:67: warning: macro `AM_PATH_ALSA' not found in library
   configure.in:67: error: possibly undefined macro: AM_PATH_ALSA
      If this token and others are legitimate, please use m4_pattern_allow.
      See the Autoconf documentation.
   autoreconf: /usr/local/bin/autoconf failed with exit status: 1

you may fix it with:
   $sudo ln -s /usr/share/aclocal /usr/aclocal

as I assume that "$aclocal --print-ac-dir" must point to the directory containing the file "alsa.m4", which was not present on my system

Revision history for this message
nickleus (nick-humphrey) wrote :

@caldrac thanks =)

Revision history for this message
dylan (mrdylanc) wrote :

Hi, I'm using ubuntu 10.04 with ubuntustudio audio packages installed, seq24 0.9.0 and I have the same issue. So I tried to compile as suggested by Caldrac but I get an error:

mainwnd.cpp:531: error: invalid conversion from ‘Gtk::ButtonBox*’ to ‘Gtk::HButtonBox*’
make[2]: *** [mainwnd.o] Error 1
make[2]: Leaving directory `/home/decomp/seq24-0.9.0/src'
make[1]: *** [all] Error 2
make[1]: Leaving directory `/home/decomp/seq24-0.9.0/src'
make: *** [all-recursive] Error 1

I found some mention of a fix here http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=504660#25 but I don't understand it. Is there something I can do to get seq24 built or working?

Revision history for this message
Niklas Park (niklas-park) wrote :

I have the same problem in 10.10.

Revision history for this message
Ronny Cardona (rcart) wrote :

Thank you for taking the time to report this bug and helping to make Ubuntu better. However, I am closing it because the bug has been fixed in the latest development version of Ubuntu - Natty Narwhal. It won't be fixed in previous versions of Ubuntu because the package doesn't fit the requirements for backporting. See https://help.ubuntu.com/community/UbuntuBackports for more information.

affects: ubuntu → seq24 (Ubuntu)
Changed in seq24 (Ubuntu):
status: New → Fix Released
Revision history for this message
magicalplug (mguh22) wrote :

I have no intention of upgrading to Natty Narwhal. It took me long enough to get Maverick Meerkat all working with my hardware, having to do plenty of hacks and trickery.

If it's impossible to fix the 'tool button' hard crash error in previous versions of Ubuntu, like you say, could someone at least provide a build WITHOUT the tool button for Maverick? It's a bit of a show stopper completely losing your work if you accidentally click this thing.

Alternatively, if anyone knows a way to compile a version with the tool button bugfix in 10.10, please post some instructions :)

Thank you.

Revision history for this message
magicalplug (mguh22) wrote :

It's ok.

Got 0.9.2 compiled using the instructions http://seq24.wikispaces.com/Compiling+Seq24+on+Ubuntu+Hardy+(8.04)
I'm using Ubuntu 10.10 64-bit.

Tool button works fine now. Hope that helps someone :)

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.