dbus-cpp's atexit handler interferes with other users of libdbus (such as Qt)
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Canonical System Image |
Fix Released
|
High
|
Thomas Voß | ||
dbus-cpp |
Fix Released
|
High
|
Thomas Voß |
Bug Description
When starting up, dbus-cpp calls init_libdbus_
For programs that also bring in Qt's D-Bus implementation (which is also built on top of libdbus), it isn't uncommon for dbus calls to be made subsequent to the atexit() handler being called, which results in errors like the following:
process 8495: arguments to dbus_connection
This is normally a bug in some application using the D-Bus library.
Ideally, the atexit handler should be removed from dbus-cpp, and add explicit dbus_shutdown() calls to the test suite to check for memory leaks. There is no real benefit to calling the function in production code, and causes real pain when mixing with Qt.
Related branches
- James Henstridge: Approve
- PS Jenkins bot: Pending (continuous-integration) requested
-
Diff: 31 lines (+13/-1)1 file modifiedsrc/core/dbus/bus.cpp (+13/-1)
- PS Jenkins bot: Needs Fixing (continuous-integration)
- Ubuntu Phablet Team: Pending requested
-
Diff: 480 lines (+190/-49) (has conflicts)9 files modifieddebian/changelog (+32/-0)
include/core/dbus/impl/object.h (+95/-34)
include/core/dbus/impl/property.h (+21/-0)
include/core/dbus/impl/signal.h (+7/-4)
include/core/dbus/object.h (+8/-7)
include/core/dbus/property.h (+8/-0)
include/core/dbus/signal.h (+5/-2)
src/core/dbus/bus.cpp (+13/-1)
src/core/dbus/service.cpp (+1/-1)
Changed in dbus-cpp: | |
status: | New → Confirmed |
importance: | Undecided → High |
assignee: | nobody → Thomas Voß (thomas-voss) |
Changed in canonical-devices-system-image: | |
status: | New → Fix Committed |
importance: | Undecided → High |
assignee: | nobody → Thomas Voß (thomas-voss) |
milestone: | none → ww02-2016 |
Changed in dbus-cpp: | |
status: | Confirmed → Fix Committed |
Changed in canonical-devices-system-image: | |
status: | Fix Committed → Fix Released |
Changed in dbus-cpp: | |
status: | Fix Committed → Fix Released |