Summary: | dbus-send doesn't print unix file descriptor types | ||
---|---|---|---|
Product: | dbus | Reporter: | Robert Ancell <robert.ancell> |
Component: | core | Assignee: | Havoc Pennington <hp> |
Status: | RESOLVED FIXED | QA Contact: | |
Severity: | normal | ||
Priority: | medium | CC: | chengwei.yang.cn |
Version: | unspecified | Keywords: | patch |
Hardware: | All | ||
OS: | All | ||
Whiteboard: | review? | ||
i915 platform: | i915 features: | ||
Attachments: |
Support printing unix file descriptors in dbus-send/dbus-monitor
Support printing unix file descriptors in dbus-send/dbus-monitor |
Description
Robert Ancell
2013-10-18 00:50:28 UTC
Comment on attachment 87806 [details] [review] Support printing unix file descriptors in dbus-send/dbus-monitor Review of attachment 87806 [details] [review]: ----------------------------------------------------------------- ::: tools/dbus-print-message.c @@ +349,5 @@ > + > + case DBUS_TYPE_UNIX_FD: > + { > + dbus_uint32_t val; > + dbus_message_iter_get_basic (iter, &val); I think the libdbus ABI is that it's an int, not a dbus_uint32_t, on platforms where that makes a difference (but please check the source code, I could be wrong). (I know it's a uint32 in the wire protocol, but the uint32 doesn't numerically equal the fd anyway.) Created attachment 87900 [details] [review] Support printing unix file descriptors in dbus-send/dbus-monitor Thanks for catching that! Looking in dbus/dbus-message.c it does indeed special case unix file descriptors and actually do the conversion from the u32 index into a file descriptor (int). Comment on attachment 87900 [details] [review] Support printing unix file descriptors in dbus-send/dbus-monitor Review of attachment 87900 [details] [review]: ----------------------------------------------------------------- looks good. patch applied, so mark it as fixed. |
Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.