summary |
shortlog |
log |
commit | commitdiff |
tree
raw |
patch |
inline | side by side (from parent 1:
b1bfd49)
With this patches i see loggings in asterisk cli by enable debugging with
core set debug 1
Signed-off-by: Andreas Eversberg <jolly@eversberg.eu>
This feature was disabled due to locking issues with older Asterisk versions.
char ast_text[128] = "NULL";
va_list args;
char ast_text[128] = "NULL";
va_list args;
+ if (!option_debug) return;
+
ast_mutex_lock(&log_lock);
va_start(args,fmt);
ast_mutex_lock(&log_lock);
va_start(args,fmt);
#endif
ast_text[sizeof(ast_text)-1] = '\0';
#endif
ast_text[sizeof(ast_text)-1] = '\0';
-// ast_log(type, file, line, function, "[call=%s ast=%s] %s", call_text, ast_text, buffer);
- printf("[call=%s ast=%s line=%d] %s", call_text, ast_text, line, buffer);
+ ast_log(type, file, line, function, "[call=%s ast=%s] %s", call_text, ast_text, buffer);
+// printf("[call=%s ast=%s line=%d] %s", call_text, ast_text, line, buffer);
ast_mutex_unlock(&log_lock);
}
ast_mutex_unlock(&log_lock);
}