Changeset 170 for trunk/src/sh_error.c
- Timestamp:
- Apr 30, 2008, 11:56:45 PM (17 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/sh_error.c
r159 r170 105 105 static int sh_error_string (struct _log_t * lmsg, va_list vl); 106 106 107 extern int sh_log_console (/*@null@*/c har *message);107 extern int sh_log_console (/*@null@*/const char *message); 108 108 extern int sh_log_syslog (int severity, /*@null@*/char *message); 109 109 extern int sh_log_file (/*@null@*/char *message, … … 173 173 174 174 static 175 void compute_flag_err_debug( )175 void compute_flag_err_debug(void) 176 176 { 177 177 if ((errFlags.loglevel & SH_ERR_ALL) != 0) … … 197 197 198 198 static 199 void compute_flag_err_info( )199 void compute_flag_err_info(void) 200 200 { 201 201 if ((errFlags.loglevel & SH_ERR_INFO) != 0) … … 220 220 } 221 221 222 void sh_error_dbg_switch( )222 void sh_error_dbg_switch(void) 223 223 { 224 224 if (dbg_flag == 0) … … 466 466 typedef struct eef 467 467 { 468 c har * str;468 const char * str; 469 469 int val; 470 470 } eef_struc; … … 797 797 /* init or re-init log facilities that need it 798 798 */ 799 void sh_error_fixup( )799 void sh_error_fixup(void) 800 800 { 801 801 #if defined(HAVE_LIBPRELUDE_9) … … 813 813 /* to be called from sh_prelude_reset 814 814 */ 815 void sh_error_init_prelude( )815 void sh_error_init_prelude(void) 816 816 { 817 817 #if defined(HAVE_LIBPRELUDE_9) … … 865 865 SH_MUTEX_RECURSIVE(mutex_err_handle); 866 866 867 void sh_error_handle (int sev, c har * file, long line,867 void sh_error_handle (int sev, const char * file, long line, 868 868 long status, unsigned long msg_id, ...) 869 869 { … … 875 875 char * fmt; 876 876 877 int flag_inet = S_FALSE;877 int flag_inet; 878 878 879 879 #ifdef SH_WITH_SERVER … … 974 974 { 975 975 flag_inet = S_TRUE; 976 } 977 else 978 { 979 flag_inet = S_FALSE; 976 980 } 977 981 … … 1355 1359 *priority = (int) msg_cat[i].priority; 1356 1360 *class = (unsigned int) msg_cat[i].class; 1357 SL_RETURN ( _(msg_cat[i].format), _("get_format"));1361 SL_RETURN (((char *) _(msg_cat[i].format)), _("get_format")); 1358 1362 } 1359 1363 ++i; … … 1545 1549 /*@i@*/required = sl_vsnprintf(&(lmsg->msg[len]), 1546 1550 (lmsg->msg_len - len), lmsg->format, vl); 1551 1547 1552 if ((required >= 0) && 1548 1553 sl_ok_adds(required, len) && … … 1556 1561 lmsg->msg_len = required + len + 4; 1557 1562 (void) sl_vsnprintf(&(lmsg->msg[len]), 1558 (required + len +1), lmsg->format, vl2);1563 (required + 1), lmsg->format, vl2); 1559 1564 } 1560 1565 va_end(vl2);
Note:
See TracChangeset
for help on using the changeset viewer.