* Added global variable silc_log_timestamp that tells silclog
[silc.git] / lib / silcutil / silclog.h
index adad8ddd15476867a103feb98b3217141be37282..0819ace625d2f821c45e9383068b757ad9783440 100644 (file)
@@ -142,6 +142,22 @@ typedef bool (*SilcLogHexdumpCb)(char *file, char *function, int line,
 
 /* Global Variables */
 
+/****v* silcutil/SilcLogAPI/silc_log_timestamp
+ *
+ * NAME
+ *
+ *    bool silc_log_timestamp -- enable/disable fast logging timestamp
+ *
+ * DESCRIPTION
+ *
+ *    Causes SilcLog to add a timestamp as returned by silc_get_time().
+ *    This may be useful for example if you run your application under a
+ *    daemon helper like watchdog that adds its own timestamp.  Defaults to
+ *    true.
+ *
+ ***/
+extern DLLAPI bool silc_log_timestamp;
+
 /****v* silcutil/SilcLogAPI/silc_log_quick
  *
  * NAME
@@ -221,8 +237,10 @@ extern DLLAPI bool silc_debug_hexdump;
 /* Macros */
 
 #ifdef SILC_WIN32
+#ifndef __FUNCTION__
 #define __FUNCTION__ ""
 #endif
+#endif
 
 /****d* silcutil/SilcLogAPI/SILC_LOG_INFO
  *
@@ -330,8 +348,11 @@ extern DLLAPI bool silc_debug_hexdump;
                                __FUNCTION__, \
                                __LINE__, \
                                silc_format fmt)
+#define SILC_NOT_IMPLEMENTED(string) \
+  SILC_LOG_DEBUG(("*********** %s: NOT IMPLEMENTED YET", string));
 #else
 #define SILC_LOG_DEBUG(fmt)
+#define SILC_NOT_IMPLEMENTED(string)
 #endif /* SILC_DEBUG */
 /***/
 
@@ -421,7 +442,8 @@ char *silc_log_get_file(SilcLogType type);
  *
  * SYNOPSIS
  *
- *    bool silc_log_set_file(SilcLogType type, char *filename, SilcUInt32 maxsize,
+ *    bool silc_log_set_file(SilcLogType type, char *filename, 
+ *                           SilcUInt32 maxsize,
  *                           SilcSchedule scheduler);
  *
  * DESCRIPTION