dbus signal and sending parameters

Thiago Macieira thiago at kde.org
Mon Dec 25 04:53:07 PST 2006

Arvind Ayyangar wrote:
>hi ppl,
> i am using dbus signals to send signals to other applications and
>then manage to send a string as a parameter to the other application
>using dbus_message_iter_append_basic(&args, DBUS_TYPE_STRING, &str).
>but who do i send a string and an integer arguments. I tried using
>dbus_message_iter_append_basic(&args, DBUS_TYPE_INT32, &integer) after
>the previous line of code but the other application never got the
>second parameter. Infact, the number of parameters to the second
>application still shows one.
>Is there some other API to do the same or am I missing out something
> very basic?

What you described seems correct: two dbus_message_iter_append_basic. 
Since that is not working, it would seem the error is somewhere else. Can 
you confirm with dbus-monitor that only a single parameter is sent?

If you can, we'd need to see the rest of the marshalling code to find out 
what's wrong. If you can't, then the bug is on the receiving 

  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: not available
Url : http://lists.freedesktop.org/archives/dbus/attachments/20061225/640ed456/attachment.pgp

More information about the dbus mailing list