1 Author: Goswin Brederlow <goswin.brederlow@student.uni-tuebingen.de> vim:ft=diff:
2 Description: Also try /dev/vc/0, devfs support (BTS #148884)
4 Index: beep-1.2.2/beep.c
5 ===================================================================
6 --- beep-1.2.2.orig/beep.c
8 @@ -239,10 +239,12 @@ void play_beep(beep_parms_t parms) {
10 /* try to snag the console */
11 if((console_fd = open("/dev/tty0", O_WRONLY)) == -1) {
12 - fprintf(stderr, "Could not open /dev/tty0 for writing.\n");
13 - printf("\a"); /* Output the only beep we can, in an effort to fall back on usefulness */
16 + if((console_fd = open("/dev/vc/0", O_WRONLY)) == -1) {
17 + fprintf(stderr, "Could not open /dev/tty0 or /dev/vc/0 for writing.\n");
18 + printf("\a"); /* Output the only beep we can, in an effort to fall back on usefulness */