Python WSGI: SERVER_NAME, SERVER_PORT fixed, REMOTE_ADDR introduced.

Shortcut: do not iterate over String (or Bytes) return object.
Call 'close()' for return object (if present).
This commit is contained in:
Max Romanov
2017-07-05 13:31:53 +03:00
parent f3107f3896
commit 41e2678110
3 changed files with 98 additions and 65 deletions

View File

@@ -1105,6 +1105,9 @@ nxt_router_conn_http_header_parse(nxt_task_t *task, void *obj, void *data)
}
c->socket.data = ap;
ap->r.remote.start = nxt_sockaddr_address(c->remote);
ap->r.remote.length = c->remote->address_length;
}
h = &ap->r.header;