Question on printf()
jian at kuhub.cc.ukans.edu
jian at kuhub.cc.ukans.edu
Fri Jun 8 02:33:21 AEST 1990
Hi folks, I have one simple question about printf() on Utrix. Following is the
program that I question about:
#define <stdio.h>
#define <signal.h>
main()
{
....
alarm(60);
....
signal(SIGALRM, display);
....
} /* main() */
display()
{
printf("\n\n\nEnter Command -> ");
alarm(60);
}
I don't know why the printf() only prints three linefeeds and the "Enter
Command -> " only shows up on every next call to display. It seems to me
that if I don't do any I/O and linefeed after printf(), the printf() does
not print the string argument on the standard output. Why? How can I avoid
this problem? I very much appreciate any helps.
Jian Li
jian at kuhub.cc.ukans.edu
More information about the Comp.unix.questions
mailing list