X-Git-Url: http://mj.ucw.cz/gitweb/?a=blobdiff_plain;ds=sidebyside;f=ucw%2Flog.h;h=f6088bcb202401610f37bce3a66e446750186f43;hb=3bf739559578b42ef385479feb602b2dfe1f41b5;hp=f2d99a0729d19e5ff79fdd06a26946743654d8d8;hpb=b6acda64c6f8fdb461fc62a03b4030bfc7f1ae07;p=libucw.git diff --git a/ucw/log.h b/ucw/log.h index f2d99a07..f6088bcb 100644 --- a/ucw/log.h +++ b/ucw/log.h @@ -11,7 +11,7 @@ #ifndef _UCW_LOG_H_ #define _UCW_LOG_H_ -#include "ucw/clists.h" +#include /*** === Messages and streams ***/ @@ -179,6 +179,17 @@ static inline struct log_stream *log_default_stream(void) return log_stream_by_flags(0); } +/** + * Make the specified stream the default destination. + * + * In fact, it takes the fixed default stream and attaches @ls as its only + * substream. If there were any other substreams, they are removed. + * + * Log streams created by log_file() or log_configured() are made default + * by calling this function. + **/ +void log_set_default_stream(struct log_stream *ls); + /** * Close all open streams, un-initialize the module, free all memory and * reset the logging mechanism to use stderr only.