mirror of
https://github.com/signalwire/freeswitch.git
synced 2026-07-24 13:12:03 +00:00
add userdata param to switch_log_printf so we can pass uuid or other session or other identification information to the logger.
git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@5412 d0543943-73ff-0310-b7d9-9358b9ac24b2
This commit is contained in:
@@ -61,7 +61,7 @@ SWITCH_BEGIN_EXTERN_C
|
||||
switch_time_t timestamp;
|
||||
/*! A pointer to where the actual content of the message starts (skipping past the preformatted portion) */
|
||||
char *content;
|
||||
|
||||
const char *userdata;
|
||||
/* To maintain abi, only add new elements to the end of this struct and do not delete any elements */
|
||||
|
||||
} switch_log_node_t;
|
||||
@@ -95,7 +95,7 @@ SWITCH_DECLARE(switch_status_t) switch_log_shutdown(void);
|
||||
\note there are channel macros to supply the first 4 parameters
|
||||
*/
|
||||
SWITCH_DECLARE(void) switch_log_printf(switch_text_channel_t channel, const char *file, const char *func, int line,
|
||||
switch_log_level_t level, const char *fmt, ...) PRINTF_FUNCTION(6, 7);
|
||||
const char *userdata, switch_log_level_t level, const char *fmt, ...) PRINTF_FUNCTION(6, 7);
|
||||
|
||||
/*!
|
||||
\brief Shut down the logging engine
|
||||
|
||||
@@ -511,9 +511,9 @@ typedef enum {
|
||||
SCSMF_DYNAMIC = (1 << 0)
|
||||
} switch_core_session_message_flag_t;
|
||||
|
||||
#define SWITCH_CHANNEL_LOG SWITCH_CHANNEL_ID_LOG, __FILE__, __SWITCH_FUNC__, __LINE__
|
||||
#define SWITCH_CHANNEL_LOG_CLEAN SWITCH_CHANNEL_ID_LOG_CLEAN, __FILE__, __SWITCH_FUNC__, __LINE__
|
||||
#define SWITCH_CHANNEL_EVENT SWITCH_CHANNEL_ID_EVENT, __FILE__, __SWITCH_FUNC__, __LINE__
|
||||
#define SWITCH_CHANNEL_LOG SWITCH_CHANNEL_ID_LOG, __FILE__, __SWITCH_FUNC__, __LINE__, NULL
|
||||
#define SWITCH_CHANNEL_LOG_CLEAN SWITCH_CHANNEL_ID_LOG_CLEAN, __FILE__, __SWITCH_FUNC__, __LINE__, NULL
|
||||
#define SWITCH_CHANNEL_EVENT SWITCH_CHANNEL_ID_EVENT, __FILE__, __SWITCH_FUNC__, __LINE__, NULL
|
||||
|
||||
/*!
|
||||
\enum switch_channel_state_t
|
||||
|
||||
Reference in New Issue
Block a user