diff options
| author | Garrett D'Amore <garrett@damore.org> | 2025-01-12 08:28:03 -0800 |
|---|---|---|
| committer | Garrett D'Amore <garrett@damore.org> | 2025-01-12 08:28:03 -0800 |
| commit | 4f445061dc9dbc1e437ff04eff6f39f021bd5bec (patch) | |
| tree | ab3f0fcb11b3b36b7081580618d7b7d0bfda0731 /src/supplemental/http/http_server.c | |
| parent | d87b873ea5bbdae1352b2a61f5110f20b65928cc (diff) | |
| download | nng-4f445061dc9dbc1e437ff04eff6f39f021bd5bec.tar.gz nng-4f445061dc9dbc1e437ff04eff6f39f021bd5bec.tar.bz2 nng-4f445061dc9dbc1e437ff04eff6f39f021bd5bec.zip | |
http: move connection properties to http_conn, use static Location for redirect
Diffstat (limited to 'src/supplemental/http/http_server.c')
| -rw-r--r-- | src/supplemental/http/http_server.c | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/src/supplemental/http/http_server.c b/src/supplemental/http/http_server.c index ffb01449..bec0c01a 100644 --- a/src/supplemental/http/http_server.c +++ b/src/supplemental/http/http_server.c @@ -714,7 +714,6 @@ http_sconn_cbdone(void *arg) { http_sconn *sc = arg; nni_aio *aio = &sc->cbaio; - nni_http_res *res; nni_http_handler *h; nni_http_server *s = sc->server; @@ -741,7 +740,6 @@ http_sconn_cbdone(void *arg) http_sconn_close(sc); return; } - res = nni_http_conn_res(sc->conn); if (!nni_http_res_sent(sc->conn)) { const char *val; const char *method; @@ -759,7 +757,7 @@ http_sconn_cbdone(void *arg) status <= 299) { // prune off data, preserving content-length header. nni_http_prune_body(sc->conn); - } else if (nni_http_res_is_error(res)) { + } else if (nni_http_is_error(sc->conn)) { (void) nni_http_server_error(s, sc->conn); } nni_http_write_res(sc->conn, &sc->txaio); |
