From: Johnathan Nightingale Date: Tue, 13 Jul 2010 23:54:01 +0000 (-0400) Subject: Gerfried's fix for serial consoles X-Git-Tag: upstream/1.3~1^2~3 X-Git-Url: https://git.deb.at/w?a=commitdiff_plain;h=0d0b32d3e8add7daedb82e565ffe2028d7e0eed0;p=pkg%2Fbeep.git Gerfried's fix for serial consoles --- diff --git a/beep.c b/beep.c index 80fc1ed..90ec837 100644 --- a/beep.c +++ b/beep.c @@ -238,8 +238,8 @@ void play_beep(beep_parms_t parms) { parms.reps, parms.length, parms.delay, parms.end_delay, parms.freq); /* try to snag the console */ - if((console_fd = open("/dev/console", O_WRONLY)) == -1) { - fprintf(stderr, "Could not open /dev/console for writing.\n"); + if((console_fd = open("/dev/tty0", O_WRONLY)) == -1) { + fprintf(stderr, "Could not open /dev/tty0 for writing.\n"); printf("\a"); /* Output the only beep we can, in an effort to fall back on usefulness */ perror("open"); exit(1);