int fputc(int c, register FILE *stream) { if (stream->__user_locking != 0) { return __PUTC_UNLOCKED_MACRO(c, stream); } else { int retval; __STDIO_ALWAYS_THREADLOCK(stream); retval = __PUTC_UNLOCKED_MACRO(c, stream); __STDIO_ALWAYS_THREADUNLOCK(stream); return retval; } }
int getchar(void) { register FILE *stream = stdin; if (stream->__user_locking != 0) { return __GETC_UNLOCKED_MACRO(stream); } else { int retval; __STDIO_ALWAYS_THREADLOCK(stream); retval = __GETC_UNLOCKED_MACRO(stream); __STDIO_ALWAYS_THREADUNLOCK(stream); return retval; } }