With the patched version of pm-utils and the test case provided I see the following in /var/log/pm-suspend.log:
Running hook /etc/pm/sleep.d/05_avoid-sleep suspend suspend:
/etc/pm/sleep.d/05_avoid-sleep suspend suspend: Returned exit code 1. Fri Jul 8 15:29:57 PDT 2011: Inhibit found, will not perform suspend
With the patched version of pm-utils and the test case provided I see the following in /var/log/ pm-suspend. log:
Running hook /etc/pm/ sleep.d/ 05_avoid- sleep suspend suspend:
/etc/pm/ sleep.d/ 05_avoid- sleep suspend suspend: Returned exit code 1.
Fri Jul 8 15:29:57 PDT 2011: Inhibit found, will not perform suspend