Arch Linux

Please read this before reporting a bug:
https://wiki.archlinux.org/title/Bug_reporting_guidelines

Do NOT report bugs when a package is just outdated, or it is in the AUR. Use the 'flag out of date' link on the package page, or the Mailing List.

REPEAT: Do NOT report bugs for outdated packages!
Tasklist

FS#16399 - [acpid] event handling not functional due to bad string parsing

Attached to Project: Arch Linux
Opened by Romain Boissat (rboissat) - Wednesday, 30 September 2009, 01:31 GMT
Last edited by Roman Kyrylych (Romashka) - Saturday, 13 February 2010, 15:58 GMT
Task Type Bug Report
Category Packages: Extra
Status Closed
Assigned To Thayer Williams (thayer)
Architecture All
Severity Low
Priority Normal
Reported Version
Due in Version Undecided
Due Date Undecided
Percent Complete 100%
Votes 0
Private No

Details

Description:
The current version of the acpid package is provided with a shell script /etc/acpi/events/anything.sh.
This is a very basic script expected to pass acpid messages in argument to /etc/acpi/handler.sh

Here is the code of the original anything.sh:

# Pass all events to our one handler script
event=.*
action=/etc/acpi/handler.sh %e

Without double quoting %e, the handler has proven to do nothing in reaction to acpi events.

This patch is fully working on my computer, allowing acpid and its event handler to be functional!

-action=/etc/acpi/handler.sh %e
+action=/etc/acpi/handler.sh "%e"

Additional info:
* package version: 1.0.10-1

Steps to reproduce:
* /etc/rc.d/acpid start
* tail -f /var/log/everything.log
* use any of acpi keys (brightness, suspend, power, whatever) or close the lid.
* observe the lack of relevant line in tail -f. Should be at least one line beginning with logger: and then some message concerning ACPI.
This task depends upon

Closed by  Roman Kyrylych (Romashka)
Saturday, 13 February 2010, 15:58 GMT
Reason for closing:  No response
Additional comments about closing:  No response in +4 months. Please reopen if necessary.
Comment by Thayer Williams (thayer) - Wednesday, 30 September 2009, 04:55 GMT
That's odd because it works fine for me with the existing anything.sh and obviously is working for many others who use the default anything. I don't see the harm in quoting %e, but I'll do some digging around before I commit to it. I've been meaning to update the handler.sh with some commented defaults anyway so now seems a good time.
Comment by Romain Boissat (rboissat) - Wednesday, 30 September 2009, 08:13 GMT
Indeed, I ran a test 1 hour ago, and it worked without quoting the string. But sometimes, I would say one time out of five, event handling is not working.
With the quoting, I get a perfect score... so I guess there is a little wtf there.

For the record, I run Arch Linux on a Lenovo X300, which is almost perfectly supported by the Linux kernel.

I'll try to investigate this issue tonight (I'm currently in Europe/Paris tz).

Thanks for the attention, and I'm sorry if I'm just rambling about a random bug ;)

Loading...