diff options
author | 2021-03-15 22:43:44 +0200 | |
---|---|---|
committer | 2021-03-15 22:43:44 +0200 | |
commit | 2b6e3cc328aabcc0dda908f16b55874487b67499 (patch) | |
tree | 40b2d1e422d8c82869b06c14f712a5bf7e39978f /include | |
parent | 850b703becdc2b13a8ef613771ee385e81e8f4f5 (diff) | |
download | librin-2b6e3cc328aabcc0dda908f16b55874487b67499.tar.gz librin-2b6e3cc328aabcc0dda908f16b55874487b67499.tar.bz2 librin-2b6e3cc328aabcc0dda908f16b55874487b67499.zip |
diagnostics: add knobs to toggle channels.
Individual channels can now be turned off and on with a simple knob
call, providing an easy way to silence a channel.
Tests not included, as deemed too trivial while being complicated to
properly test.
Signed-off-by: Gediminas Jakutis <gediminas@varciai.lt>
Diffstat (limited to 'include')
-rw-r--r-- | include/rin/diagnostic.h | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/include/rin/diagnostic.h b/include/rin/diagnostic.h index 7941c8a..6d37dee 100644 --- a/include/rin/diagnostic.h +++ b/include/rin/diagnostic.h @@ -34,6 +34,7 @@ enum rin_diag_outstream { void rin_diag_init(void); int rin_diag_format(const enum rin_diag_outstream, const char * const format); int rin_diag_set_outstream(const enum rin_diag_outstream channel, FILE * const stream); +int rin_diag_channel_set_enabled_state(const enum rin_diag_outstream channel, const unsigned int enable); void __rin_err(const char * const func_name, int line_num, const char * const file_name, const char *format, ...) FORMAT_STRING(4, 5); void __rin_warn(const char * const func_name, int line_num, const char * const file_name, const char *format, ...) FORMAT_STRING(4, 5); |