Threading problems in WinDBus

Olivier Hochreutiner olivier.hochreutiner at gmail.com
Fri Jul 6 14:08:58 PDT 2007


Hi!

> If you send along a backtrace (one with function names, i.e. with debug
> info available) from the crash it might be revealing.

As I said the assert does not occur at the same place every time (and
not in the same thread either), so I attached 3 backtraces (running
under Windows).

> Another thing to try is just see if the same bug exists on unix so you
> know whether it's a Windows-specific issue.

As I said at the top of my previous post, the problem is not
Windows-specific: the same happens under Debian 4.0 with the last
version of D-Bus from CVS. When using the version distributed with
Debian (which is the 1.0.2) it ends up with a segfault, probably
because asserts are disabled.

I also tried to get the output with DBUS_VERBOSE=1 but strangely I
cannot reproduce the problem with verbose output. It is likely that
the extra I/O prevent in some way the race condition to happen (since
it seems to be a race condition ?).

Best,

Olivier
-------------- next part --------------
	SandBoxDBus.exe!_NMSG_WRITE(int rterrnum=10)  Line 198	C
 	SandBoxDBus.exe!abort()  Line 59 + 0x7 bytes	C
 	SandBoxDBus.exe!_dbus_abort()  Line 87	C
 	SandBoxDBus.exe!_dbus_real_assert(unsigned int condition=0, const char * condition_text=0x006044cc, const char * file=0x0060449c, int line=935, const char * func=0x00604478)  Line 819	C
 	SandBoxDBus.exe!free_pending_call_on_hash_removal(void * data=0x01ca9570)  Line 935 + 0x5d bytes	C
 	SandBoxDBus.exe!free_entry_data(DBusHashTable * table=0x01ca26c8, DBusHashEntry * entry=0x01ca3898)  Line 458 + 0x11 bytes	C
 	SandBoxDBus.exe!free_entry(DBusHashTable * table=0x01ca26c8, DBusHashEntry * entry=0x01ca3898)  Line 465 + 0xd bytes	C
 	SandBoxDBus.exe!remove_entry(DBusHashTable * table=0x01ca26c8, DBusHashEntry * * bucket=0x01ca26d4, DBusHashEntry * entry=0x01ca3898)  Line 495 + 0xd bytes	C
 	SandBoxDBus.exe!_dbus_hash_table_remove_int(DBusHashTable * table=0x01ca26c8, int key=234)  Line 1349 + 0x11 bytes	C
 	SandBoxDBus.exe!_dbus_connection_detach_pending_call_and_unlock(DBusConnection * connection=0x01ca2748, DBusPendingCall * pending=0x01ca9570)  Line 963 + 0x19 bytes	C
 	SandBoxDBus.exe!complete_pending_call_and_unlock(DBusConnection * connection=0x01ca2748, DBusPendingCall * pending=0x01ca9570, DBusMessage * message=0x01cbde60)  Line 2163 + 0xd bytes	C
 	SandBoxDBus.exe!check_for_reply_and_update_dispatch_unlocked(DBusConnection * connection=0x01ca2748, DBusPendingCall * pending=0x01ca9570)  Line 2185 + 0x11 bytes	C
 	SandBoxDBus.exe!_dbus_connection_block_pending_call(DBusPendingCall * pending=0x01ca9570)  Line 2290 + 0xd bytes	C
 	SandBoxDBus.exe!dbus_pending_call_block(DBusPendingCall * pending=0x01ca9570)  Line 707 + 0x9 bytes	C
 	SandBoxDBus.exe!dbus_connection_send_with_reply_and_block(DBusConnection * connection=0x01ca2748, DBusMessage * message=0x01ca3530, int timeout_milliseconds=2000, DBusError * error=0x0100fb14)  Line 3265 + 0x9 bytes	C
 	SandBoxDBus.exe!DBus::Connection::send_blocking(DBus::Message & msg={...}, int timeout=2000)  Line 337 + 0x2b bytes	C++
 	SandBoxDBus.exe!DBus::ObjectProxy::_invoke_method(DBus::CallMessage & call={...})  Line 324 + 0x1f bytes	C++
 	SandBoxDBus.exe!DBus::InterfaceProxy::invoke_method(const DBus::CallMessage & call={...})  Line 159 + 0x31 bytes	C++
 	SandBoxDBus.exe!org::freedesktop::DBus::EchoDemo::Hello(const std::basic_string<char,std::char_traits<char>,std::allocator<char> > & name="test")  Line 50 + 0x13 bytes	C++
 	SandBoxDBus.exe!wmain(int argc=1, wchar_t * * argv=0x00395ef8)  Line 30 + 0x2a bytes	C++
 	SandBoxDBus.exe!__tmainCRTStartup()  Line 327 + 0x19 bytes	C
 	SandBoxDBus.exe!wmainCRTStartup()  Line 196	C

-------------- next part --------------
>	SandBoxDBus.exe!_NMSG_WRITE(int rterrnum=10)  Line 198	C
 	SandBoxDBus.exe!abort()  Line 59 + 0x7 bytes	C
 	SandBoxDBus.exe!_dbus_abort()  Line 87	C
 	SandBoxDBus.exe!_dbus_real_assert(unsigned int condition=0, const char * condition_text=0x00604ad0, const char * file=0x00604aa0, int line=1082, const char * func=0x00604a7c)  Line 819	C
 	SandBoxDBus.exe!_dbus_connection_release_io_path(DBusConnection * connection=0x01ca2748)  Line 1082 + 0x2c bytes	C
 	SandBoxDBus.exe!_dbus_connection_handle_watch(DBusWatch * watch=0x01ca2cf8, unsigned int condition=1, void * data=0x01ca2748)  Line 1419 + 0x9 bytes	C
 	SandBoxDBus.exe!dbus_watch_handle(DBusWatch * watch=0x01ca2cf8, unsigned int flags=1)  Line 660 + 0x19 bytes	C
 	SandBoxDBus.exe!DBus::Watch::handle(int flags=1)  Line 84 + 0x10 bytes	C++
 	SandBoxDBus.exe!DBus::BusDispatcher::watch_ready(DBus::EepleWatch & ew={...})  Line 424	C++
 	SandBoxDBus.exe!DBus::Callback<DBus::BusDispatcher,void,DBus::EepleWatch &>::call(DBus::EepleWatch & param={...})  Line 262 + 0x1a bytes	C++
 	SandBoxDBus.exe!DBus::Slot<void,DBus::EepleWatch &>::operator()(DBus::EepleWatch & param={...})  Line 231 + 0x1d bytes	C++
 	SandBoxDBus.exe!DBus::EepleMainLoop::dispatch()  Line 269	C++
 	SandBoxDBus.exe!DBus::BusDispatcher::do_iteration()  Line 350 + 0x13 bytes	C++
 	SandBoxDBus.exe!DBus::BusDispatcher::enter()  Line 326 + 0xf bytes	C++
 	SandBoxDBus.exe!dispthreadfct(void * a=0x00000000)  Line 13 + 0x14 bytes	C++

-------------- next part --------------
>	SandBoxDBus.exe!_NMSG_WRITE(int rterrnum=10)  Line 198	C
 	SandBoxDBus.exe!abort()  Line 59 + 0x7 bytes	C
 	SandBoxDBus.exe!_dbus_abort()  Line 87	C
 	SandBoxDBus.exe!_dbus_real_assert(unsigned int condition=0, const char * condition_text=0x00603704, const char * file=0x006036d4, int line=362, const char * func=0x006036bc)  Line 819	C
 	SandBoxDBus.exe!_dbus_connection_unlock(DBusConnection * connection=0x01ca2748)  Line 362 + 0x47 bytes	C
 	SandBoxDBus.exe!dbus_pending_call_unref(DBusPendingCall * pending=0x01ca63e8)  Line 575 + 0xc bytes	C
 	SandBoxDBus.exe!complete_pending_call_and_unlock(DBusConnection * connection=0x01ca2748, DBusPendingCall * pending=0x01ca63e8, DBusMessage * message=0x01cb4908)  Line 2167 + 0x9 bytes	C
 	SandBoxDBus.exe!check_for_reply_and_update_dispatch_unlocked(DBusConnection * connection=0x01ca2748, DBusPendingCall * pending=0x01ca63e8)  Line 2185 + 0x11 bytes	C
 	SandBoxDBus.exe!_dbus_connection_block_pending_call(DBusPendingCall * pending=0x01ca63e8)  Line 2290 + 0xd bytes	C
 	SandBoxDBus.exe!dbus_pending_call_block(DBusPendingCall * pending=0x01ca63e8)  Line 707 + 0x9 bytes	C
 	SandBoxDBus.exe!dbus_connection_send_with_reply_and_block(DBusConnection * connection=0x01ca2748, DBusMessage * message=0x01ca3530, int timeout_milliseconds=2000, DBusError * error=0x0100fb14)  Line 3265 + 0x9 bytes	C
 	SandBoxDBus.exe!DBus::Connection::send_blocking(DBus::Message & msg={...}, int timeout=2000)  Line 337 + 0x2b bytes	C++
 	SandBoxDBus.exe!DBus::ObjectProxy::_invoke_method(DBus::CallMessage & call={...})  Line 324 + 0x1f bytes	C++
 	SandBoxDBus.exe!DBus::InterfaceProxy::invoke_method(const DBus::CallMessage & call={...})  Line 159 + 0x31 bytes	C++
 	SandBoxDBus.exe!org::freedesktop::DBus::EchoDemo::Hello(const std::basic_string<char,std::char_traits<char>,std::allocator<char> > & name="test")  Line 50 + 0x13 bytes	C++
 	SandBoxDBus.exe!wmain(int argc=1, wchar_t * * argv=0x00395ef8)  Line 30 + 0x2a bytes	C++
 	SandBoxDBus.exe!__tmainCRTStartup()  Line 327 + 0x19 bytes	C
 	SandBoxDBus.exe!wmainCRTStartup()  Line 196	C

-------------- next part --------------
>	SandBoxDBus.exe!_NMSG_WRITE(int rterrnum=10)  Line 198	C
 	SandBoxDBus.exe!abort()  Line 59 + 0x7 bytes	C
 	SandBoxDBus.exe!_dbus_abort()  Line 87	C
 	SandBoxDBus.exe!_dbus_real_assert(unsigned int condition=0, const char * condition_text=0x00604ad0, const char * file=0x00604aa0, int line=1082, const char * func=0x00604a7c)  Line 819	C
 	SandBoxDBus.exe!_dbus_connection_release_io_path(DBusConnection * connection=0x01ca2748)  Line 1082 + 0x2c bytes	C
 	SandBoxDBus.exe!_dbus_connection_handle_watch(DBusWatch * watch=0x01ca2cf8, unsigned int condition=1, void * data=0x01ca2748)  Line 1419 + 0x9 bytes	C
 	SandBoxDBus.exe!dbus_watch_handle(DBusWatch * watch=0x01ca2cf8, unsigned int flags=1)  Line 660 + 0x19 bytes	C
 	SandBoxDBus.exe!DBus::Watch::handle(int flags=1)  Line 84 + 0x10 bytes	C++
 	SandBoxDBus.exe!DBus::BusDispatcher::watch_ready(DBus::EepleWatch & ew={...})  Line 424	C++
 	SandBoxDBus.exe!DBus::Callback<DBus::BusDispatcher,void,DBus::EepleWatch &>::call(DBus::EepleWatch & param={...})  Line 262 + 0x1a bytes	C++
 	SandBoxDBus.exe!DBus::Slot<void,DBus::EepleWatch &>::operator()(DBus::EepleWatch & param={...})  Line 231 + 0x1d bytes	C++
 	SandBoxDBus.exe!DBus::EepleMainLoop::dispatch()  Line 269	C++
 	SandBoxDBus.exe!DBus::BusDispatcher::do_iteration()  Line 350 + 0x13 bytes	C++
 	SandBoxDBus.exe!DBus::BusDispatcher::enter()  Line 326 + 0xf bytes	C++
 	SandBoxDBus.exe!dispthreadfct(void * a=0x00000000)  Line 13 + 0x14 bytes	C++



More information about the dbus mailing list