Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

now we allow the DDEBUG macro to be defined globally from outside.

  • Loading branch information...
commit 27b0b347cc60b25fe0e3e41015a16d79ea9545f4 1 parent c866c1d
@agentzh agentzh authored
View
2  src/ngx_http_redis2_handler.c
@@ -1,4 +1,6 @@
+#ifndef DDEBUG
#define DDEBUG 0
+#endif
#include "ddebug.h"
#include "ngx_http_redis2_handler.h"
View
2  src/ngx_http_redis2_module.c
@@ -1,4 +1,6 @@
+#ifndef DDEBUG
#define DDEBUG 0
+#endif
#include "ddebug.h"
#include "ngx_http_redis2_module.h"
View
40 src/ngx_http_redis2_reply.c
@@ -1,6 +1,8 @@
#line 1 "src/ngx_http_redis2_reply.rl"
+#ifndef DDEBUG
#define DDEBUG 0
+#endif
#include "ddebug.h"
#include "ngx_http_redis2_reply.h"
@@ -8,11 +10,11 @@
#include <nginx.h>
-#line 18 "src/ngx_http_redis2_reply.rl"
+#line 20 "src/ngx_http_redis2_reply.rl"
-#line 16 "src/ngx_http_redis2_reply.c"
+#line 18 "src/ngx_http_redis2_reply.c"
static const int reply_start = 1;
static const int reply_first_final = 50;
static const int reply_error = 0;
@@ -20,7 +22,7 @@ static const int reply_error = 0;
static const int reply_en_main = 1;
-#line 21 "src/ngx_http_redis2_reply.rl"
+#line 23 "src/ngx_http_redis2_reply.rl"
ngx_int_t
ngx_http_redis2_process_reply(ngx_http_redis2_ctx_t *ctx,
@@ -52,12 +54,12 @@ ngx_http_redis2_process_reply(ngx_http_redis2_ctx_t *ctx,
dd("init the state machine");
-#line 56 "src/ngx_http_redis2_reply.c"
+#line 58 "src/ngx_http_redis2_reply.c"
{
cs = reply_start;
}
-#line 52 "src/ngx_http_redis2_reply.rl"
+#line 54 "src/ngx_http_redis2_reply.rl"
ctx->state = cs;
@@ -72,7 +74,7 @@ ngx_http_redis2_process_reply(ngx_http_redis2_ctx_t *ctx,
dd("response body: %.*s", (int) bytes, p);
-#line 76 "src/ngx_http_redis2_reply.c"
+#line 78 "src/ngx_http_redis2_reply.c"
{
short _widec;
if ( p == pe )
@@ -160,7 +162,7 @@ case 5:
if ( ++p == pe )
goto _test_eof50;
case 50:
-#line 164 "src/ngx_http_redis2_reply.c"
+#line 166 "src/ngx_http_redis2_reply.c"
goto st0;
st6:
if ( ++p == pe )
@@ -211,7 +213,7 @@ case 8:
if ( ++p == pe )
goto _test_eof9;
case 9:
-#line 215 "src/ngx_http_redis2_reply.c"
+#line 217 "src/ngx_http_redis2_reply.c"
if ( (*p) == 13 )
goto st10;
if ( 48 <= (*p) && (*p) <= 57 )
@@ -389,7 +391,7 @@ case 13:
if ( ++p == pe )
goto _test_eof51;
case 51:
-#line 393 "src/ngx_http_redis2_reply.c"
+#line 395 "src/ngx_http_redis2_reply.c"
_widec = (*p);
if ( (*p) < 13 ) {
if ( (*p) <= 12 ) {
@@ -500,7 +502,7 @@ case 16:
if ( ++p == pe )
goto _test_eof17;
case 17:
-#line 504 "src/ngx_http_redis2_reply.c"
+#line 506 "src/ngx_http_redis2_reply.c"
if ( (*p) == 13 )
goto st18;
if ( 48 <= (*p) && (*p) <= 57 )
@@ -524,7 +526,7 @@ case 18:
if ( ++p == pe )
goto _test_eof19;
case 19:
-#line 528 "src/ngx_http_redis2_reply.c"
+#line 530 "src/ngx_http_redis2_reply.c"
_widec = (*p);
if ( (*p) < 43 ) {
if ( 36 <= (*p) && (*p) <= 36 ) {
@@ -730,7 +732,7 @@ case 23:
if ( ++p == pe )
goto _test_eof52;
case 52:
-#line 734 "src/ngx_http_redis2_reply.c"
+#line 736 "src/ngx_http_redis2_reply.c"
_widec = (*p);
if ( (*p) < 43 ) {
if ( 36 <= (*p) && (*p) <= 36 ) {
@@ -1015,7 +1017,7 @@ case 28:
if ( ++p == pe )
goto _test_eof29;
case 29:
-#line 1019 "src/ngx_http_redis2_reply.c"
+#line 1021 "src/ngx_http_redis2_reply.c"
_widec = (*p);
if ( (*p) > 13 ) {
if ( 48 <= (*p) && (*p) <= 57 ) {
@@ -1343,7 +1345,7 @@ case 33:
if ( ++p == pe )
goto _test_eof53;
case 53:
-#line 1347 "src/ngx_http_redis2_reply.c"
+#line 1349 "src/ngx_http_redis2_reply.c"
_widec = (*p);
if ( (*p) < 43 ) {
if ( (*p) < 14 ) {
@@ -2526,7 +2528,7 @@ case 40:
if ( ++p == pe )
goto _test_eof54;
case 54:
-#line 2530 "src/ngx_http_redis2_reply.c"
+#line 2532 "src/ngx_http_redis2_reply.c"
_widec = (*p);
if ( (*p) < 43 ) {
if ( (*p) > 13 ) {
@@ -2758,7 +2760,7 @@ case 41:
if ( ++p == pe )
goto _test_eof55;
case 55:
-#line 2762 "src/ngx_http_redis2_reply.c"
+#line 2764 "src/ngx_http_redis2_reply.c"
_widec = (*p);
if ( (*p) < 43 ) {
if ( (*p) < 14 ) {
@@ -3299,7 +3301,7 @@ case 43:
if ( ++p == pe )
goto _test_eof44;
case 44:
-#line 3303 "src/ngx_http_redis2_reply.c"
+#line 3305 "src/ngx_http_redis2_reply.c"
_widec = (*p);
if ( (*p) < 14 ) {
if ( (*p) > 12 ) {
@@ -3618,7 +3620,7 @@ case 46:
if ( ++p == pe )
goto _test_eof56;
case 56:
-#line 3622 "src/ngx_http_redis2_reply.c"
+#line 3624 "src/ngx_http_redis2_reply.c"
_widec = (*p);
if ( (*p) < 44 ) {
if ( (*p) < 36 ) {
@@ -4044,7 +4046,7 @@ case 49:
_out: {}
}
-#line 66 "src/ngx_http_redis2_reply.rl"
+#line 68 "src/ngx_http_redis2_reply.rl"
dd("state after exec: %d, done: %d, %.*s", cs, (int) done,
(int) (bytes - ((u_char *) p - b->last)), p);
View
2  src/ngx_http_redis2_reply.rl
@@ -1,4 +1,6 @@
+#ifndef DDEBUG
#define DDEBUG 0
+#endif
#include "ddebug.h"
#include "ngx_http_redis2_reply.h"
View
2  src/ngx_http_redis2_util.c
@@ -1,4 +1,6 @@
+#ifndef DDEBUG
#define DDEBUG 0
+#endif
#include "ddebug.h"
#include "ngx_http_redis2_util.h"
Please sign in to comment.
Something went wrong with that request. Please try again.