mirror of
https://github.com/nginx/nginx.git
synced 2025-06-07 17:52:38 +08:00
change useless ngx_pcalloc() to ngx_pnalloc()
This commit is contained in:
parent
96a1ea9d22
commit
f2a1484347
@ -649,7 +649,7 @@ sendfile(r, filename, offset = -1, bytes = 0)
|
|||||||
|
|
||||||
path.len = ngx_strlen(filename);
|
path.len = ngx_strlen(filename);
|
||||||
|
|
||||||
path.data = ngx_pcalloc(r->pool, path.len + 1);
|
path.data = ngx_pnalloc(r->pool, path.len + 1);
|
||||||
if (path.data == NULL) {
|
if (path.data == NULL) {
|
||||||
XSRETURN_EMPTY;
|
XSRETURN_EMPTY;
|
||||||
}
|
}
|
||||||
|
@ -528,7 +528,7 @@ ngx_mail_auth_http_process_headers(ngx_mail_session_t *s,
|
|||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
|
|
||||||
p = ngx_pcalloc(s->connection->pool, size);
|
p = ngx_pnalloc(s->connection->pool, size);
|
||||||
if (p == NULL) {
|
if (p == NULL) {
|
||||||
ngx_close_connection(ctx->peer.connection);
|
ngx_close_connection(ctx->peer.connection);
|
||||||
ngx_destroy_pool(ctx->pool);
|
ngx_destroy_pool(ctx->pool);
|
||||||
|
Loading…
Reference in New Issue
Block a user