[Previous] [Contents] [Next]

putc_unlocked()

Write a character to an output stream

Synopsis:

#include <stdio.h>

int putc_unlocked( int c, 
                   FILE *stream );

Library:

libc

Description:

The putc_unlocked() function is a thread-unsafe version of putc(). It can be used safely only when the invoking thread has locked stream using flockfile() (or ftrylockfile()) and funlockfile().

Returns:

The character written, cast as (int)(unsigned char), or EOF if an error occurred (errno is set).

Classification:

POSIX 1003.1

Safety:
Cancellation point Yes
Interrupt handler No
Signal handler No
Thread No

See also:

getc(), getchar(), getchar_unlocked(), getc_unlocked(), putc(), putchar(), putchar_unlocked()


[Previous] [Contents] [Next]