DBus threading question

Thiago Macieira thiago at kde.org
Wed Dec 10 23:51:00 PST 2008


Schmottlach, Glenn wrote:
>How do both threads block on the same transport without interfering with
> one another (e.g. who gets the first chance to check for messages and
> handle it)?

They don't.

Only one can block the transport at a time.

It's recommended that the thread that is listening for external events 
(incoming signals and calls) not block the transport, but instead use 
select(2) or poll(2) to be notified of activity.

-- 
  Thiago Macieira  -  thiago (AT) macieira.info - thiago (AT) kde.org
    PGP/GPG: 0x6EF45358; fingerprint:
    E067 918B B660 DBD1 105C  966C 33F5 F005 6EF4 5358
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: This is a digitally signed message part.
Url : http://lists.freedesktop.org/archives/dbus/attachments/20081211/5cf8a52f/attachment.pgp 


More information about the dbus mailing list