mirror of
https://github.com/alsa-project/alsa-tools.git
synced 2025-10-29 05:40:25 -04:00
ac3dec: Show usage if no parameter is passed
When ac3dec is called without any argument the application hangs forever. Instead of hanging, print the usage and exit. Signed-off-by: Fabio Estevam <fabio.estevam@freescale.com> Signed-off-by: Takashi Iwai <tiwai@suse.de>
This commit is contained in:
parent
e875fa883d
commit
848e26d10e
1 changed files with 5 additions and 0 deletions
|
|
@ -130,6 +130,11 @@ int main(int argc,char *argv[])
|
|||
out_config.spdif = SPDIF_NONE;
|
||||
out_config.hdmi = 0;
|
||||
|
||||
if (isatty(fileno(stdin)) && (argc == 1)) {
|
||||
help();
|
||||
return 1;
|
||||
}
|
||||
|
||||
morehelp = 0;
|
||||
while (1) {
|
||||
int c;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue