Skip to content

Commit 7031273

Browse files
change: change grammar of error log.
1 parent 4b3fb72 commit 7031273

File tree

2 files changed

+11
-13
lines changed

2 files changed

+11
-13
lines changed

src/ngx_http_lua_bodyfilterby.c

Lines changed: 10 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -271,10 +271,9 @@ ngx_http_lua_body_filter(ngx_http_request_t *r, ngx_chain_t *in)
271271
/* continue to call ngx_http_next_body_filter to process cached data */
272272
}
273273

274-
if (in != NULL) {
275-
if (ngx_chain_add_copy(r->pool, &ctx->filter_in_bufs, in) != NGX_OK) {
276-
return NGX_ERROR;
277-
}
274+
if (in != NULL
275+
&& ngx_chain_add_copy(r->pool, &ctx->filter_in_bufs, in) != NGX_OK) {
276+
return NGX_ERROR;
278277
}
279278

280279
if (ctx->filter_busy_bufs != NULL
@@ -299,14 +298,13 @@ ngx_http_lua_body_filter(ngx_http_request_t *r, ngx_chain_t *in)
299298
ngx_chain_update_chains(r->pool,
300299
&ctx->free_bufs, &ctx->filter_busy_bufs, &out,
301300
(ngx_buf_tag_t) &ngx_http_lua_module);
302-
if (rc != NGX_OK) {
303-
if (ctx->filter_busy_bufs != NULL
304-
&& (r->connection->buffered
305-
& (NGX_HTTP_LOWLEVEL_BUFFERED | NGX_LOWLEVEL_BUFFERED))) {
306-
ngx_log_debug0(NGX_LOG_DEBUG_HTTP, r->connection->log, 0,
307-
"waiting body filter busy buffer to be sent");
308-
return NGX_AGAIN;
309-
}
301+
if (rc != NGX_OK
302+
&& ctx->filter_busy_bufs != NULL
303+
&& (r->connection->buffered
304+
& (NGX_HTTP_LOWLEVEL_BUFFERED | NGX_LOWLEVEL_BUFFERED))) {
305+
ngx_log_debug0(NGX_LOG_DEBUG_HTTP, r->connection->log, 0,
306+
"waiting body filter busy buffer to be sent");
307+
return NGX_AGAIN;
310308
}
311309

312310
/* continue to process bufs in ctx->filter_in_bufs */

src/ngx_http_lua_output.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -247,7 +247,7 @@ ngx_http_lua_ngx_echo(lua_State *L, unsigned newline)
247247
ngx_log_debug2(NGX_LOG_DEBUG_HTTP, r->connection->log, 0,
248248
"%s has %sbusy bufs",
249249
newline ? "lua say response" : "lua print response",
250-
ctx->busy_bufs != NULL ? "" : "not ");
250+
ctx->busy_bufs != NULL ? "" : "no ");
251251

252252
dd("downstream write: %d, buf len: %d", (int) rc,
253253
(int) (b->last - b->pos));

0 commit comments

Comments
 (0)