#define rsts 1 #include #include puts(s) char *s; { fputss(s, stdout); } fputss(s, fp) char *s; FILE *fp; { char c; int is_rec; if (is_rec = (fp->io_flag & IO_REC)) fp->io_flag &= ~IO_REC; while (c = *s++) putc(c, fp); putc('\n', fp); if (is_rec) { fp->io_flag |= IO_REC; fflush(fp); } } fputs(s, fp) char *s; FILE *fp; { char c; int is_rec; if (is_rec = (fp->io_flag & IO_REC)) fp->io_flag &= ~IO_REC; while (c = *s++) putc(c, fp); if (is_rec) { fp->io_flag |= IO_REC; fflush(fp); } }