From: Dave Reisner Date: Sun, 12 Jan 2014 16:15:52 +0000 (-0500) Subject: alsa-restore.rules: refer to correct attr X-Git-Tag: v1.0.28~17 X-Git-Url: https://git.alsa-project.org/?a=commitdiff_plain;h=ef0e588c76fbad4112193d311e51a60d18b44282;p=alsa-utils.git alsa-restore.rules: refer to correct attr $attr{number} in the RUN rule is an empty expansion. This makes sense, because the path doesn't exist -- i.e., it refers to the path: /sys/devices/pci0000:00/foo/bar/sound/card0/controlC0/number Instead, refer to $attr{device/number}, which does exist. Signed-off-by: Dave Reisner Signed-off-by: Takashi Iwai --- diff --git a/alsactl/90-alsa-restore.rules.in b/alsactl/90-alsa-restore.rules.in index 88e12e0..c68119d 100644 --- a/alsactl/90-alsa-restore.rules.in +++ b/alsactl/90-alsa-restore.rules.in @@ -2,7 +2,7 @@ ACTION=="add", SUBSYSTEM=="sound", KERNEL=="controlC*", KERNELS!="card*", GOTO=" GOTO="alsa_restore_end" LABEL="alsa_restore_go" -TEST!="@daemonswitch@", RUN+="@sbindir@/alsactl restore $attr{number}" -TEST=="@daemonswitch@", RUN+="@sbindir@/alsactl nrestore $attr{number}" +TEST!="@daemonswitch@", RUN+="@sbindir@/alsactl restore $attr{device/number}" +TEST=="@daemonswitch@", RUN+="@sbindir@/alsactl nrestore $attr{device/number}" LABEL="alsa_restore_end"