|
Tou
Tou header library
|
Macros | |
| #define | TOU_SILENCE(...) |
| Shorthand for surrounding a piece of code with tou_disable_stdout and tou_enable_stdout. | |
Functions | |
| int | tou_disable_stdout () |
Redirects STDOUT to /dev/null (or NUL: on Windows) | |
| void | tou_enable_stdout (int saved_fd) |
| Re-enables STDOUT that had been disabled using the saved file descriptor from previous function. | |
Variables | |
| int | _tou_g_saved_stdout |
| Filedescriptor handle local to this compilation unit used with TOU_SILENCE. | |
| #define TOU_SILENCE | ( | ... | ) |
Shorthand for surrounding a piece of code with tou_disable_stdout and tou_enable_stdout.
| int tou_disable_stdout | ( | ) |
Redirects STDOUT to /dev/null (or NUL: on Windows)
Return value should be saved if you wish to restore STDOUT function.
| void tou_enable_stdout | ( | int | saved_fd | ) |
Re-enables STDOUT that had been disabled using the saved file descriptor from previous function.
| [in] | saved_fd | Saved STDOUT fd |
| int _tou_g_saved_stdout |
Filedescriptor handle local to this compilation unit used with TOU_SILENCE.
Since it isn't surrounded by #ifdef TOU_IMPLEMENTATION it'll be declared each time you #include the header.