]> git.ipfire.org Git - thirdparty/freeswitch.git/commitdiff
char * -> const char *
authorMichael Jerris <mike@jerris.com>
Mon, 18 Dec 2006 04:32:50 +0000 (04:32 +0000)
committerMichael Jerris <mike@jerris.com>
Mon, 18 Dec 2006 04:32:50 +0000 (04:32 +0000)
git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@3691 d0543943-73ff-0310-b7d9-9358b9ac24b2

src/include/switch_log.h
src/include/switch_types.h
src/switch_core.c
src/switch_log.c

index 75765bf9b583d75788607d28fb585a9adebfb373..5942a3437095047eea6b1bb6121a150028b9da1f 100644 (file)
@@ -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
index 0bde31743121062ea983137f473e02ed6d7d2c5f..14e144b5f870dcaf94a86e7c8f90899ab9c66776 100644 (file)
@@ -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
index 748566cb85f2c16beae7bbdf1354ad8c6f80cd0f..f1d93cded20e588a03a342b1be9d5ec44ac15ae0 100644 (file)
@@ -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)
 {
index 622c735d73ac43d848d62f3b90307b56414c5091..059e5af0eced66f46be820db11cee86a4ea1ae40 100644 (file)
@@ -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();