Skip to content

Commit bb7a267

Browse files
committed
bugfix: fixed errors and warnings with C compilers without variadic macro support.
1 parent bb56424 commit bb7a267

File tree

1 file changed

+9
-4
lines changed

1 file changed

+9
-4
lines changed

src/ddebug.h

Lines changed: 9 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
#ifndef DDEBUG_H
22
#define DDEBUG_H
33

4+
45
#include <ngx_config.h>
56
#include <ngx_core.h>
67
#include <ngx_http.h>
@@ -22,7 +23,8 @@
2223

2324
#include <stdarg.h>
2425

25-
static void dd(const char * fmt, ...) {
26+
static ngx_inline void
27+
dd(const char * fmt, ...) {
2628
}
2729

2830
# endif
@@ -38,7 +40,8 @@ static void dd(const char * fmt, ...) {
3840
# define dd_main_req_count 0
3941
# endif
4042

41-
static void dd_enter_helper(ngx_http_request_t *r, const char *func) {
43+
static ngx_inline void
44+
dd_enter_helper(ngx_http_request_t *r, const char *func) {
4245
ngx_http_posted_request_t *pr;
4346

4447
fprintf(stderr, ">enter %s %.*s %.*s?%.*s c:%d m:%p r:%p ar:%p pr:%p",
@@ -78,10 +81,12 @@ static void dd_enter_helper(ngx_http_request_t *r, const char *func) {
7881

7982
#include <stdarg.h>
8083

81-
static void dd(const char * fmt, ...) {
84+
static ngx_inline void
85+
dd(const char * fmt, ...) {
8286
}
8387

84-
static void dd_enter() {
88+
static ngx_inline void
89+
dd_enter() {
8590
}
8691

8792
# endif

0 commit comments

Comments
 (0)