[PATCH] do not call _dbus_warn_check_failed on checks

Daniel Stone daniel at fooishbar.org
Tue Nov 14 02:10:05 PST 2006

On Tue, Nov 14, 2006 at 10:48:32AM +0100, Thiago Macieira wrote:
> I don't think it's reasonable to expect that all applications will support 
> restart.
> For one thing, the default behaviour of libdbus-1 is to call exit(3) if 
> the connection disconnects. So, the reasonable thing is to expect 
> applications to exit if the bus restarts.

Given this insane constraint (very, very, very Xlib-like), then no, it's
not reasonable, because of absolutely ridiculous library behaviour.

> For another, there might be a lot of state kept in the applications that 
> may or may not be transferred to the new connection. This is especially 
> true for the unique connection names, which will be restarted. Other 
> problems also include race conditions when a call comes in just after 
> restart and the target wasn't yet present, etc.

It's difficult, and you can never get it absolutely, perfectly,
bullet-proof, 100% bug-free.  But you can optimise for the common case
and get it right 99.9% of the time.  And when the planets align and
conspire against you to cause one tiny minor failure in an extreme
corner case, then it's still better than exit(3), which works for
exactly 0.0% of the cases.

-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: Digital signature
Url : http://lists.freedesktop.org/archives/dbus/attachments/20061114/3f2fe686/attachment-0001.pgp

More information about the dbus mailing list