]> git.alsa-project.org Git - alsa-utils.git/commit
amixer: Parse the value more strictly
authorTakashi Iwai <tiwai@suse.de>
Sun, 23 Nov 2014 09:04:24 +0000 (10:04 +0100)
committerTakashi Iwai <tiwai@suse.de>
Sun, 23 Nov 2014 09:04:24 +0000 (10:04 +0100)
commit088593c03980209c44a9e9cde19723361d341c0a
treec6d9f6a897d45a61660166265431380134772e37
parent45a334e71ca9b4402fb731a934f7455cec5b0121
amixer: Parse the value more strictly

So far amixer allows some unexpected suffix and assumes as a raw
absolute value without returning an error.  This is rather dangerous,
e.g. user might not notice that a completely wrong value was set when
the command line included a typo.

This patch makes the parser a bit more strict: it doesn't allow any
longer invalid suffixes, instead either returns an error or skips the
invalid value, depending on the operation mode.

Signed-off-by: Takashi Iwai <tiwai@suse.de>
amixer/amixer.c