summaryrefslogtreecommitdiff
path: root/src/sp_utils.c
diff options
context:
space:
mode:
authorjvoisin2017-10-10 12:12:10 +0200
committerjvoisin2017-10-10 12:12:10 +0200
commit18711c04c9e6fc6056f79f05598719a112ecbba5 (patch)
tree34016121eb1ecba352d1eb8bcb341ffcfe645db8 /src/sp_utils.c
parent6c89a3e68e109ab9e6ef5445c00ea786cd59c89c (diff)
Make the `simulation` mode logs more obvious
Diffstat (limited to 'src/sp_utils.c')
-rw-r--r--src/sp_utils.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/src/sp_utils.c b/src/sp_utils.c
index f696a55..0ddc024 100644
--- a/src/sp_utils.c
+++ b/src/sp_utils.c
@@ -231,14 +231,14 @@ void sp_log_disable(const char* restrict path, const char* restrict arg_name,
231 const int sim = config_node->simulation; 231 const int sim = config_node->simulation;
232 if (arg_name) { 232 if (arg_name) {
233 if (alias) { 233 if (alias) {
234 sp_log_msg("disabled_function", sim?SP_LOG_NOTICE:SP_LOG_DROP, 234 sp_log_msg("disabled_function", sim?SP_LOG_SIMULATION:SP_LOG_DROP,
235 "The call to the function '%s' in %s:%d has been disabled, " 235 "The call to the function '%s' in %s:%d has been disabled, "
236 "because its argument '%s' content (%s) matched the rule '%s'.", 236 "because its argument '%s' content (%s) matched the rule '%s'.",
237 path, zend_get_executed_filename(TSRMLS_C), 237 path, zend_get_executed_filename(TSRMLS_C),
238 zend_get_executed_lineno(TSRMLS_C), arg_name, arg_value?arg_value:"?", 238 zend_get_executed_lineno(TSRMLS_C), arg_name, arg_value?arg_value:"?",
239 alias); 239 alias);
240 } else { 240 } else {
241 sp_log_msg("disabled_function", sim?SP_LOG_NOTICE:SP_LOG_DROP, 241 sp_log_msg("disabled_function", sim?SP_LOG_SIMULATION:SP_LOG_DROP,
242 "The call to the function '%s' in %s:%d has been disabled, " 242 "The call to the function '%s' in %s:%d has been disabled, "
243 "because its argument '%s' content (%s) matched a rule.", 243 "because its argument '%s' content (%s) matched a rule.",
244 path, zend_get_executed_filename(TSRMLS_C), 244 path, zend_get_executed_filename(TSRMLS_C),
@@ -247,13 +247,13 @@ void sp_log_disable(const char* restrict path, const char* restrict arg_name,
247 } 247 }
248 } else { 248 } else {
249 if (alias) { 249 if (alias) {
250 sp_log_msg("disabled_function", sim?SP_LOG_NOTICE:SP_LOG_DROP, 250 sp_log_msg("disabled_function", sim?SP_LOG_SIMULATION:SP_LOG_DROP,
251 "The call to the function '%s' in %s:%d has been disabled, " 251 "The call to the function '%s' in %s:%d has been disabled, "
252 "because of the the rule '%s'.",path, 252 "because of the the rule '%s'.",path,
253 zend_get_executed_filename(TSRMLS_C), 253 zend_get_executed_filename(TSRMLS_C),
254 zend_get_executed_lineno(TSRMLS_C), alias); 254 zend_get_executed_lineno(TSRMLS_C), alias);
255 } else { 255 } else {
256 sp_log_msg("disabled_function", sim?SP_LOG_NOTICE:SP_LOG_DROP, 256 sp_log_msg("disabled_function", sim?SP_LOG_SIMULATION:SP_LOG_DROP,
257 "The call to the function '%s' in %s:%d has been disabled.", 257 "The call to the function '%s' in %s:%d has been disabled.",
258 path, zend_get_executed_filename(TSRMLS_C), 258 path, zend_get_executed_filename(TSRMLS_C),
259 zend_get_executed_lineno(TSRMLS_C)); 259 zend_get_executed_lineno(TSRMLS_C));
@@ -271,13 +271,13 @@ void sp_log_disable_ret(const char* restrict path,
271 const char* alias = config_node->alias; 271 const char* alias = config_node->alias;
272 const int sim = config_node->simulation; 272 const int sim = config_node->simulation;
273 if (alias) { 273 if (alias) {
274 sp_log_msg("disabled_function", sim?SP_LOG_NOTICE:SP_LOG_DROP, 274 sp_log_msg("disabled_function", sim?SP_LOG_SIMULATION:SP_LOG_DROP,
275 "The execution has been aborted in %s:%d, " 275 "The execution has been aborted in %s:%d, "
276 "because the function '%s' returned '%s', which matched the rule '%s'.", 276 "because the function '%s' returned '%s', which matched the rule '%s'.",
277 zend_get_executed_filename(TSRMLS_C), 277 zend_get_executed_filename(TSRMLS_C),
278 zend_get_executed_lineno(TSRMLS_C), path, ret_value?ret_value:"?", alias); 278 zend_get_executed_lineno(TSRMLS_C), path, ret_value?ret_value:"?", alias);
279 } else { 279 } else {
280 sp_log_msg("disabled_function", sim?SP_LOG_NOTICE:SP_LOG_DROP, 280 sp_log_msg("disabled_function", sim?SP_LOG_SIMULATION:SP_LOG_DROP,
281 "The execution has been aborted in %s:%d, " 281 "The execution has been aborted in %s:%d, "
282 "because the return value (%s) of the function '%s' matched a rule.", 282 "because the return value (%s) of the function '%s' matched a rule.",
283 zend_get_executed_filename(TSRMLS_C), 283 zend_get_executed_filename(TSRMLS_C),