Bug 84598 - Provide an example for GetAllMatchRules
Summary: Provide an example for GetAllMatchRules
Status: RESOLVED FIXED
Alias: None
Product: dbus
Classification: Unclassified
Component: core (show other bugs)
Version: unspecified
Hardware: Other All
: medium normal
Assignee: D-Bus Maintainers
QA Contact: D-Bus Maintainers
URL:
Whiteboard:
Keywords: patch
Depends on:
Blocks:
 
Reported: 2014-10-02 14:00 UTC by Alban Crequy
Modified: 2014-10-06 11:33 UTC (History)
0 users

See Also:
i915 platform:
i915 features:


Attachments
[PATCH] GetAllMatchRules: provide an example how it could be used (5.16 KB, patch)
2014-10-02 14:00 UTC, Alban Crequy
Details | Splinter Review

Description Alban Crequy 2014-10-02 14:00:02 UTC
Created attachment 107228 [details] [review]
[PATCH] GetAllMatchRules: provide an example how it could be used

GetAllMatchRules (Bug #24307) was added in dbus 1.9.0 but without an example how it could be used to debug D-Bus systems.

GetAllMatchRules is useful to find applications registering too broad D-Bus match rules. The attached script shows how it could be done. It could be installed in /usr/share/doc/dbus/examples/.
Comment 1 Simon McVittie 2014-10-06 11:07:55 UTC
Comment on attachment 107228 [details] [review]
[PATCH] GetAllMatchRules: provide an example how it could be used

Review of attachment 107228 [details] [review]:
-----------------------------------------------------------------

> FIXME: why do I need to add GetAllMatchRules.py in EXTRA_DIST?
> "make distcheck" does not work otherwise...

automake-1.14.info ยง9.1 "Executable Scripts":

     # Install my_script in $(bindir) and distribute it.
     dist_bin_SCRIPTS = my_script

   Scripts are not distributed by default; as we have just seen, those
that should be distributed can be specified using a 'dist_' prefix as
with other primaries.

(The justification for not distributing them by default is that they often use the "foo.in" idiom to substitute @datadir@ or @PYTHON@ or whatever.)
Comment 2 Simon McVittie 2014-10-06 11:33:26 UTC
(In reply to Simon McVittie from comment #1)
>    Scripts are not distributed by default; as we have just seen, those
> that should be distributed can be specified using a 'dist_' prefix as
> with other primaries.

Fixed that for you, and committed it for 1.9.2. Thanks!


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.