Connection dropped with extended ascii strings

Havoc Pennington hp at pobox.com
Thu Dec 11 08:58:12 PST 2008


Hi,

On Thu, Dec 11, 2008 at 10:13 AM, Per Inge Mathisen
<per.inge.mathisen at sonowand.com> wrote:
> Thanks for your help. I take it that the fix mentioned above is not yet
> implemented?

No, it isn't

> Can this alternative disconnect handler know the reason for the
> disconnect somehow? An application that is required to be robust needs
> to be able to recover from connections dropped due to errors, but should
> still go down if the session itself is going down. But to do that it has
> to know the difference.

The connection won't be dropped due to any error that isn't a bug in
the app - the only errors that cause drops are well-formedness issues
(syntax errors, corrupt data, etc.)

In other words, in a non-buggy app, all disconnections mean the
session has ended.

> I can certainly understand why the message would be dropped, but
> terminating the entire connection seems unwarranted. It makes it far
> harder than it ought to be to write robust applications.

In theory, libdbus shouldn't allow through any corrupt messages that
will cause the daemon to drop you; it should catch them all with a
warning on the client side.

But this warning is missing for invalid utf8.

Havoc


More information about the dbus mailing list