Restore the "GPL licensing not permitted" in GLUT license headers.
[haiku.git] / headers / posix / stdio_post.h
blob71a841dfc2d055934e05b4cd6adb461b516aba96
1 /*
2 * Copyright 2003-2012 Haiku, Inc. All Rights Reserved.
3 * Distributed under the terms of the MIT License.
4 */
5 #ifndef _STDIO_POST_H_
6 #define _STDIO_POST_H_
9 /* "Private"/inline functions of our BeOS compatible stdio implementation */
11 /* ToDo: this is a work in progress to make our stdio
12 * BeOS' GNU/libio (almost) binary compatible
13 * We may not yet be compatible! */
15 #ifndef _STDIO_H_
16 # error "This file must be included from stdio.h!"
17 #endif
19 #ifdef __cplusplus
20 extern "C" {
21 #endif
23 extern char _single_threaded;
24 /* this boolean value is true (1) if there is only the main thread
25 * running - as soon as you spawn the first thread, it's set to
26 * false (0) */
28 #ifdef __cplusplus
30 #endif
32 #define getc(stream) \
33 (_single_threaded ? getc_unlocked(stream) : getc(stream))
34 #define putc(c, stream) \
35 (_single_threaded ? putc_unlocked(c, stream) : putc(c, stream))
37 #endif /* _STDIO_POST_H_ */