Welcome! Log In Create A New Profile

Advanced

[PATCH 6 of 8] Disabled freeing recv buffer when asynchronous recv IO is in running

SoYun Seong
November 24, 2020 03:46AM
# HG changeset patch
# User SoYun Seong <thdbsdox12@gmail.com>
# Date 1606129149 0
# Mon Nov 23 10:59:09 2020 +0000
# Node ID 57e46378828172e06b32b11d4c059ff0a7213d0d
# Parent bdf6d23007d53d9b76a7666c8db7ece864e31038
Disabled freeing recv buffer when asynchronous recv IO is in running.

diff -r bdf6d23007d5 -r 57e463788281 src/http/ngx_http_request.c
--- a/src/http/ngx_http_request.c Mon Nov 23 10:56:29 2020 +0000
+++ b/src/http/ngx_http_request.c Mon Nov 23 10:59:09 2020 +0000
@@ -444,8 +444,10 @@
* We are trying to not hold c->buffer's memory for an idle connection.
*/

- if (ngx_pfree(c->pool, b->start) == NGX_OK) {
- b->start = NULL;
+ if(!(ngx_event_flags & NGX_USE_URING_EVENT)) {
+ if (ngx_pfree(c->pool, b->start) == NGX_OK) {
+ b->start = NULL;
+ }
}

return;
@@ -3317,13 +3319,15 @@
* c->buffer's memory for a keepalive connection.
*/

- if (ngx_pfree(c->pool, b->start) == NGX_OK) {
-
- /*
- * the special note that c->buffer's memory was freed
- */
-
- b->pos = NULL;
+ if(!(ngx_event_flags & NGX_USE_URING_EVENT)) {
+ if (ngx_pfree(c->pool, b->start) == NGX_OK) {
+
+ /*
+ * the special note that c->buffer's memory was freed
+ */
+
+ b->pos = NULL;
+ }
}

return;
_______________________________________________
nginx-devel mailing list
nginx-devel@nginx.org
http://mailman.nginx.org/mailman/listinfo/nginx-devel
Subject Author Views Posted

[PATCH 6 of 8] Disabled freeing recv buffer when asynchronous recv IO is in running

SoYun Seong 87 November 24, 2020 03:46AM



Sorry, you do not have permission to post/reply in this forum.

Online Users

Guests: 56
Record Number of Users: 6 on February 13, 2018
Record Number of Guests: 421 on December 02, 2018
Powered by nginx      Powered by FreeBSD      PHP Powered      Powered by MariaDB      ipv6 ready