mirror of
https://github.com/clearlinux/uwsgi.git
synced 2026-10-03 23:48:22 +00:00
add empty QUERY_STRING in http server
This commit is contained in:
@@ -172,6 +172,8 @@ static void *http_request(void *u_h_r)
|
||||
|
||||
ptr = tmp_buf;
|
||||
|
||||
int qs = 0;
|
||||
|
||||
up = uwsgipkt;
|
||||
|
||||
char *watermark = up + 4096 ;
|
||||
@@ -206,10 +208,15 @@ static void *http_request(void *u_h_r)
|
||||
path_info_len = j;
|
||||
if (j + 1 < (ptr - tmp_buf)) {
|
||||
up = add_uwsgi_var(up, "QUERY_STRING", 12, tmp_buf + j + 1, (ptr - tmp_buf) - (j + 1), 0, watermark);
|
||||
qs = 1 ;
|
||||
}
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
if (!qs) {
|
||||
up = add_uwsgi_var(up, "QUERY_STRING", 12, NULL, 0, 0, watermark);
|
||||
}
|
||||
up = add_uwsgi_var(up, "PATH_INFO", 9, tmp_buf, path_info_len, 0, watermark);
|
||||
|
||||
ptr = tmp_buf;
|
||||
|
||||
Reference in New Issue
Block a user