pcspkr piano should exit if it can't open spkr [ci skip]
This commit is contained in:
parent
9e2721eef0
commit
478835401e
@ -39,6 +39,7 @@ int main(int argc, char * argv[]) {
|
||||
spkr = open("/dev/spkr", O_WRONLY);
|
||||
if (spkr == -1) {
|
||||
fprintf(stderr, "%s: could not open speaker\n", argv[0]);
|
||||
return 1;
|
||||
}
|
||||
|
||||
set_unbuffered();
|
||||
|
Loading…
Reference in New Issue
Block a user