Skip to content

Commit 2cc788b

Browse files
committed
improved the fix in commit 48e4830.
1 parent 48e4830 commit 2cc788b

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

src/ngx_http_lua_socket_tcp.c

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -883,6 +883,10 @@ ngx_http_lua_socket_resolve_handler(ngx_resolver_ctx_t *ctx)
883883
if (waiting) {
884884
dd("run posted requests");
885885
ngx_http_run_posted_requests(c);
886+
887+
} else {
888+
lua_pushnil(L);
889+
lua_pushliteral(L, "no memory");
886890
}
887891
}
888892

@@ -2531,9 +2535,6 @@ ngx_http_lua_socket_handle_conn_error(ngx_http_request_t *r,
25312535
"lua tcp socket waking up the current request");
25322536

25332537
r->write_event_handler(r);
2534-
2535-
} else {
2536-
u->write_prepare_retvals(r, u, coctx->co);
25372538
}
25382539
}
25392540

0 commit comments

Comments
 (0)