diff options
author | ghazi <ghazi@138bc75d-0d04-0410-961f-82ee72b054a4> | 2002-06-01 12:38:32 +0000 |
---|---|---|
committer | ghazi <ghazi@138bc75d-0d04-0410-961f-82ee72b054a4> | 2002-06-01 12:38:32 +0000 |
commit | 0fa1f522915088d7bcbf7c9492fa70dc6cddaa17 (patch) | |
tree | c6c7b1fe59f3ddb8b8ccf102855193850daecdfc /libf2c/libF77/s_paus.c | |
parent | bc09eb06ee8c1540503d5314a71617de2151fbf2 (diff) | |
download | gcc-0fa1f522915088d7bcbf7c9492fa70dc6cddaa17.tar.gz |
* libF77/*: Fix formatting.
* libI77/*: Likewise.
* libU77/*: Likewise.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@54145 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'libf2c/libF77/s_paus.c')
-rw-r--r-- | libf2c/libF77/s_paus.c | 92 |
1 files changed, 48 insertions, 44 deletions
diff --git a/libf2c/libF77/s_paus.c b/libf2c/libF77/s_paus.c index 34f48616324..79691366e6f 100644 --- a/libf2c/libF77/s_paus.c +++ b/libf2c/libF77/s_paus.c @@ -7,61 +7,65 @@ #undef min #undef max #include <stdlib.h> -extern int getpid(void), isatty(int), pause(void); +extern int getpid (void), isatty (int), pause (void); -extern void f_exit(void); +extern void f_exit (void); static void -waitpause(Sigarg) -{ Use_Sigarg; - return; - } +waitpause (Sigarg) +{ + Use_Sigarg; + return; +} static void -s_1paus(FILE *fin) +s_1paus (FILE * fin) { - fprintf(stderr, - "To resume execution, type go. Other input will terminate the job.\n"); - fflush(stderr); - if( getc(fin)!='g' || getc(fin)!='o' || getc(fin)!='\n' ) { - fprintf(stderr, "STOP\n"); + fprintf (stderr, + "To resume execution, type go. Other input will terminate the job.\n"); + fflush (stderr); + if (getc (fin) != 'g' || getc (fin) != 'o' || getc (fin) != '\n') + { + fprintf (stderr, "STOP\n"); #ifdef NO_ONEXIT - f_exit(); + f_exit (); #endif - exit(0); - } - } + exit (0); + } +} - int -s_paus(char *s, ftnlen n) +int +s_paus (char *s, ftnlen n) { - fprintf(stderr, "PAUSE "); - if(n > 0) - fprintf(stderr, " %.*s", (int)n, s); - fprintf(stderr, " statement executed\n"); - if( isatty(fileno(stdin)) ) - s_1paus(stdin); - else { + fprintf (stderr, "PAUSE "); + if (n > 0) + fprintf (stderr, " %.*s", (int) n, s); + fprintf (stderr, " statement executed\n"); + if (isatty (fileno (stdin))) + s_1paus (stdin); + else + { #if (defined (MSDOS) && !defined (GO32)) || defined (_WIN32) - FILE *fin; - fin = fopen("con", "r"); - if (!fin) { - fprintf(stderr, "s_paus: can't open con!\n"); - fflush(stderr); - exit(1); - } - s_1paus(fin); - fclose(fin); + FILE *fin; + fin = fopen ("con", "r"); + if (!fin) + { + fprintf (stderr, "s_paus: can't open con!\n"); + fflush (stderr); + exit (1); + } + s_1paus (fin); + fclose (fin); #else - fprintf(stderr, - "To resume execution, execute a kill -%d %d command\n", - PAUSESIG, getpid() ); - signal1(PAUSESIG, waitpause); - fflush(stderr); - pause(); + fprintf (stderr, + "To resume execution, execute a kill -%d %d command\n", + PAUSESIG, getpid ()); + signal1 (PAUSESIG, waitpause); + fflush (stderr); + pause (); #endif - } - fprintf(stderr, "Execution resumes after PAUSE.\n"); - fflush(stderr); - return 0; /* NOT REACHED */ + } + fprintf (stderr, "Execution resumes after PAUSE.\n"); + fflush (stderr); + return 0; /* NOT REACHED */ } |