diff options
author | Havoc Pennington <hp@redhat.com> | 2003-03-16 21:01:57 +0000 |
---|---|---|
committer | Havoc Pennington <hp@redhat.com> | 2003-03-16 21:01:57 +0000 |
commit | d1f65c6c4f9dd9750f9ad3eda5b590a4ffca6498 (patch) | |
tree | a5e6728794bc55602755fc7fff1eb51613222ade /bus/dispatch.c | |
parent | ebb57e719c32becd95a1efe3dd269c21e5a011b6 (diff) |
2003-03-16 Havoc Pennington <hp@pobox.com>
* dbus/dbus-bus.c (ensure_bus_data): handle failure to set
connection data
* dbus/dbus-memory.c (_dbus_initialize_malloc_debug): support
DBUS_MALLOC_BACKTRACES to print trace when failing an alloc
Diffstat (limited to 'bus/dispatch.c')
-rw-r--r-- | bus/dispatch.c | 12 |
1 files changed, 11 insertions, 1 deletions
diff --git a/bus/dispatch.c b/bus/dispatch.c index 3c96d704..639b9509 100644 --- a/bus/dispatch.c +++ b/bus/dispatch.c @@ -412,7 +412,16 @@ static dbus_bool_t check_no_leftovers (BusContext *context); static void flush_bus (BusContext *context) -{ +{ + /* This is race condition city, obviously. since we're all in one + * process we can't block, we just have to wait for data we put in + * one end of the debug pipe to come out the other end... + * a more robust setup would be good. + */ + + while (bus_loop_iterate (FALSE)) + ; + _dbus_sleep_milliseconds (15); while (bus_loop_iterate (FALSE)) ; } @@ -863,6 +872,7 @@ check_hello_connection (BusContext *context) _dbus_assert_not_reached ("message other than disconnect dispatched after failure to register"); dbus_connection_unref (connection); _dbus_assert (!bus_test_client_listed (connection)); + return TRUE; } else |