提交 855c7b9a authored 作者: Michael Jerris's avatar Michael Jerris

char * -> const char *

git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@3691 d0543943-73ff-0310-b7d9-9358b9ac24b2
上级 d7400bf3
......@@ -94,7 +94,7 @@ SWITCH_DECLARE(switch_status_t) switch_log_shutdown(void);
\param ... variable args
\note there are channel macros to supply the first 4 parameters
*/
SWITCH_DECLARE(void) switch_log_printf(switch_text_channel_t channel, char *file, char *func, int line, switch_log_level_t level, char *fmt, ...);
SWITCH_DECLARE(void) switch_log_printf(switch_text_channel_t channel, const char *file, const char *func, int line, switch_log_level_t level, char *fmt, ...);
/*!
\brief Shut down the logging engine
......
......@@ -393,9 +393,9 @@ typedef enum {
} switch_core_session_message_flag_t;
#define SWITCH_UUID_FORMATTED_LENGTH APR_UUID_FORMATTED_LENGTH
#define SWITCH_CHANNEL_LOG SWITCH_CHANNEL_ID_LOG, __FILE__, (char *) __FUNCTION__, __LINE__
#define SWITCH_CHANNEL_LOG_CLEAN SWITCH_CHANNEL_ID_LOG_CLEAN, __FILE__, (char *)__FUNCTION__, __LINE__
#define SWITCH_CHANNEL_EVENT SWITCH_CHANNEL_ID_EVENT, __FILE__, (char *)__FUNCTION__, __LINE__
#define SWITCH_CHANNEL_LOG SWITCH_CHANNEL_ID_LOG, __FILE__, __FUNCTION__, __LINE__
#define SWITCH_CHANNEL_LOG_CLEAN SWITCH_CHANNEL_ID_LOG_CLEAN, __FILE__, __FUNCTION__, __LINE__
#define SWITCH_CHANNEL_EVENT SWITCH_CHANNEL_ID_EVENT, __FILE__, __FUNCTION__, __LINE__
/*!
\enum switch_channel_state_t
......
......@@ -2308,7 +2308,7 @@ SWITCH_DECLARE(switch_status_t) switch_core_session_write_frame(switch_core_sess
SWITCH_DECLARE(switch_status_t) switch_core_session_perform_kill_channel(switch_core_session_t *session,
const char *file,
char *func,
const char *func,
int line,
switch_signal_t sig)
{
......
......@@ -162,14 +162,14 @@ static void *SWITCH_THREAD_FUNC log_thread(switch_thread_t *thread, void *obj)
return NULL;
}
SWITCH_DECLARE(void) switch_log_printf(switch_text_channel_t channel, char *file, char *func, int line, switch_log_level_t level, char *fmt, ...)
SWITCH_DECLARE(void) switch_log_printf(switch_text_channel_t channel, const char *file, const char *func, int line, switch_log_level_t level, char *fmt, ...)
{
char *data = NULL;
char *new_fmt = NULL;
int ret = 0;
va_list ap;
FILE *handle;
char *filep = (file ? switch_cut_path(file): "");
const char *filep = (file ? (const char *)switch_cut_path((char *)file): "");
const char *funcp = (func ? func : "");
char *content = NULL;
switch_time_t now = switch_time_now();
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论