Bug 669889 - [abrt] audacious-2.4.3-1.fc15: adplug / C++ static initialization order crash (SIGSEGV)
Summary: [abrt] audacious-2.4.3-1.fc15: adplug / C++ static initialization order crash...
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Fedora
Classification: Fedora
Component: audacious-plugins
Version: rawhide
Hardware: x86_64
OS: Unspecified
low
medium
Target Milestone: ---
Assignee: Michael Schwendt
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard: abrt_hash:974c511758b635770c2f4ef3570...
: 676246 (view as bug list)
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2011-01-15 15:04 UTC by Clyde E. Kunkel
Modified: 2013-11-04 00:49 UTC (History)
7 users (show)

Fixed In Version: audacious-2.4.4-1.fc15
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2011-03-03 03:40:42 UTC
Type: ---
Embargoed:


Attachments (Terms of Use)
File: backtrace (17.57 KB, text/plain)
2011-01-15 15:05 UTC, Clyde E. Kunkel
no flags Details
backtrace with more debuginfos (21.83 KB, text/plain)
2011-01-15 21:40 UTC, Michael Schwendt
no flags Details

Description Clyde E. Kunkel 2011-01-15 15:04:58 UTC
abrt version: 1.1.14
architecture: x86_64
Attached file: backtrace
cmdline: audacious2
component: audacious
executable: /usr/bin/audacious2
kernel: 2.6.37-2.fc15.x86_64
package: audacious-2.4.3-1.fc15
reason: Process /usr/bin/audacious2 was killed by signal 11 (SIGSEGV)
release: Fedora release 15 (Rawhide)
time: 1295103978
uid: 500

comment
-----
just invoke from gnome menu.  If from a gnome terminal, see this:
Segmentation fault (core dumped)

How to reproduce
-----
1. install audacious on rawhide on 20110115
2. invoke from gnome menu
3.

Comment 1 Clyde E. Kunkel 2011-01-15 15:05:00 UTC
Created attachment 473646 [details]
File: backtrace

Comment 2 Michael Schwendt 2011-01-15 17:21:51 UTC
The backtrace you attached is useless because it's missing too many debuginfo packages. Can you please try to refresh it in ABRT (or after running "debuginfo-install audacious-plugins audacious" as root)?

> #0  0x00007f1a2e7d4628 in ?? () from /usr/lib64/audacious/Input/adplug.so

So, it crashed somewhere in the Adplug plugin, which hasn't changed compared with the previous build (2.4.2).

Comment 3 Michael Schwendt 2011-01-15 21:40:07 UTC
Created attachment 473671 [details]
backtrace with more debuginfos

Comment 4 Michael Schwendt 2011-01-15 21:45:17 UTC
Looks like libstdc++ breakage to me - unless the adplug code does something nasty in C++ that would no longer be okay in Rawhide. Can reproduce with a fresh install of Rawhide (x86_64), but not with F14 (i686).

Comment 5 Michael Schwendt 2011-01-16 10:03:39 UTC
Some observations [albeit clueless yet]:

 * last GCC package set update in Rawhide is from Nov 30th,
   which is _before_ the last build of Audacious (2.4.2) on Dec 9th

 * downgrading to audacious-plugins-2.4.2-1.fc15 from Dec 9th works:
   http://koji.fedoraproject.org/koji/buildinfo?buildID=208615

 * the adplug source between audacious-plugins 2.4.2 and 2.4.3 has not changed,
   the entire diff is just 18k

 * rebuilding both audacious + audacious-plugins 2.4.2-1.fc15 from Dec 9th
   with Rawhide (20110115) also segfaults at run-time
   => something after Dec 9th must be the culprit

 * from the working koji builds from Dec 9th, rebuilding just
   audacious-plugins-2.4.2-1.fc15 on today's Rawhide segfaults, too

Comment 6 Clyde E. Kunkel 2011-01-16 15:37:53 UTC
(In reply to comment #2)
> The backtrace you attached is useless because it's missing too many debuginfo
> packages. Can you please try to refresh it in ABRT (or after running
> "debuginfo-install audacious-plugins audacious" as root)?
> 
> > #0  0x00007f1a2e7d4628 in ?? () from /usr/lib64/audacious/Input/adplug.so
> 
> So, it crashed somewhere in the Adplug plugin, which hasn't changed compared
> with the previous build (2.4.2).

You are far more adept at debugging than I, so I will assume needinfo is satisfied.  BTW, abrt usually tells you what debuginfo to install, but hasn't been doing this recently.

Comment 7 Michael Schwendt 2011-01-17 00:57:30 UTC
Haven't found anything concrete, so taking this ticket back for now and trying to find out whether there's sporadic memory corruption somewhere that would not be visible from time to time.

Comment 8 Michael Schwendt 2011-01-18 21:55:01 UTC
// gcc $(pkg-config --cflags --libs gmodule-2.0) so_open.c -o so_open
// requires: audacious-plugins-2.4.3-1.fc15.x86_64.rpm
// http://koji.fedoraproject.org/koji/buildinfo?buildID=214193

#include <stdlib.h>
#include <gmodule.h>

int main(int argc, char** argv) {
    GModule *m;
    m = g_module_open("/usr/lib64/audacious/Input/adplug.so",G_MODULE_BIND_LAZY | G_MODULE_BIND_LOCAL);
    g_module_close(m);
    exit(0);
}

Shortest test-case I'm continueing with. (Using libdl/dlopen instead of
gmodule also crashes, fwiw.)

Wonder whether there's illegal C++ in adplug.so which may have worked
so far only coincidentally (e.g. including Fedora 14)? The code initializes
a few static const class members, one time it inherits from std::list, and
all that is related to the backtrace as well.

Comment 9 Michel Lind 2011-02-06 17:49:09 UTC
audacious no longer crashes for me with the latest libstdc++-4.6.0-0.6.fc15.x86_64 -- and that test script returns an exit status of 0. I still get this on stderr, though:


(process:19302): GModule-CRITICAL **: g_module_close: assertion `module != NULL' failed

Comment 10 Michael Schwendt 2011-02-06 18:00:51 UTC
To run the test in recent Rawhide you need to "yum -y install audacious-plugins-adplug" since the crashing plugin has been moved out into its own subpackage (not just because it crashed, but also because it has a very small target group).

Comment 11 Michael Schwendt 2011-02-09 10:52:24 UTC
*** Bug 676246 has been marked as a duplicate of this bug. ***

Comment 12 Kevin Kofler 2011-02-16 19:10:59 UTC
This code is relying on the static class member CAdPlug::players (declared in core/adplug.h and defined in core/adplug.cxx) to get initialized before the file-scope static variable conf in adplug-xmms.cc. Initialization order of global and static variables in C++ is not defined, in particular, the compiler will not automatically figure out the dependencies to initialize stuff in the correct order. This code has a 50% chance of working, it's just luck that it worked so far.

Comment 13 Michael Schwendt 2011-02-16 20:17:44 UTC
Thanks, Kevin! That and skimming over [basic.stc.static] and [stmt.dcl] in the C++ Standard sounds plausible. I've missed the cross-dependency between the two translation units and have only noticed that the code appears to be convoluted.

Comment 14 Fedora Update System 2011-02-17 01:31:44 UTC
audacious-plugins-2.4.3-9.fc15 has been submitted as an update for Fedora 15.
https://admin.fedoraproject.org/updates/audacious-plugins-2.4.3-9.fc15

Comment 15 Fedora Update System 2011-02-17 22:25:14 UTC
audacious-plugins-2.4.3-10.fc15 has been pushed to the Fedora 15 testing repository.  If problems still persist, please make note of it in this bug report.
 If you want to test the update, you can install it with 
 su -c 'yum --enablerepo=updates-testing update audacious-plugins'.  You can provide feedback for this update here: https://admin.fedoraproject.org/updates/audacious-plugins-2.4.3-10.fc15

Comment 16 Fedora Update System 2011-02-23 14:45:34 UTC
audacious-2.4.4-1.fc15,audacious-plugins-2.4.4-1.fc15 has been submitted as an update for Fedora 15.
https://admin.fedoraproject.org/updates/audacious-2.4.4-1.fc15,audacious-plugins-2.4.4-1.fc15

Comment 17 Fedora Update System 2011-02-23 20:29:50 UTC
audacious-2.4.4-1.fc15, audacious-plugins-2.4.4-1.fc15 has been pushed to the Fedora 15 testing repository.  If problems still persist, please make note of it in this bug report.
 If you want to test the update, you can install it with 
 su -c 'yum --enablerepo=updates-testing update audacious audacious-plugins'.  You can provide feedback for this update here: https://admin.fedoraproject.org/updates/audacious-2.4.4-1.fc15,audacious-plugins-2.4.4-1.fc15

Comment 18 Fedora Update System 2011-03-03 03:40:31 UTC
audacious-2.4.4-1.fc15, audacious-plugins-2.4.4-1.fc15 has been pushed to the Fedora 15 stable repository.  If problems still persist, please make note of it in this bug report.


Note You need to log in before you can comment on or make changes to this bug.