Skip to content

Commit

Permalink
refactor: remove all debug logs
Browse files Browse the repository at this point in the history
  • Loading branch information
ADD-SP committed Mar 10, 2024
1 parent 48acd8f commit 218d62c
Show file tree
Hide file tree
Showing 10 changed files with 0 additions and 722 deletions.
43 changes: 0 additions & 43 deletions inc/ngx_http_waf_module_macro.h
Original file line number Diff line number Diff line change
Expand Up @@ -359,47 +359,4 @@
#define ngx_is_null_str(s) ((s) == NULL || (s)->data == NULL || (s)->len == 0 || ((s)->data[0] == '\0' && (s)->len == 1))


#ifndef NGX_HTTP_WAF_NO_DEBUG
#define ngx_http_waf_dp_func_start(r) { \
if (r != NULL) { \
ngx_http_waf_dpf(r, "%s start", __func__); \
} \
}


#define ngx_http_waf_dp(r, str) { \
if (r != NULL) { \
ngx_log_error(NGX_LOG_DEBUG, (r)->connection->log, 0, \
"ngx_waf_debug: ["str"] at %s:%s:%d, ngx_waf %s", __func__, __FILE__, __LINE__, NGX_HTTP_WAF_VERSION); \
} \
}


#define ngx_http_waf_dpf(r, fmt, ...) { \
if (r != NULL) { \
ngx_log_error(NGX_LOG_DEBUG, (r)->connection->log, 0, \
"ngx_waf_debug: ["fmt"] at %s:%s:%d, ngx_waf %s", __VA_ARGS__, __func__, __FILE__, __LINE__, NGX_HTTP_WAF_VERSION); \
} \
}


#define ngx_http_waf_dp_func_end(r) { \
if (r != NULL) { \
ngx_http_waf_dpf(r, "%s end", __func__); \
} \
}
#else
#define ngx_http_waf_dp_func_start(...) {}


#define ngx_http_waf_dp(...) {}


#define ngx_http_waf_dpf(...) {}


#define ngx_http_waf_dp_func_end(...) {}
#endif


#endif // !NGX_HTTP_WAF_MODULE_MACRO_H
Loading

0 comments on commit 218d62c

Please sign in to comment.