mirror of
https://github.com/samba-team/samba.git
synced 2025-01-11 05:18:09 +03:00
s4:web_server/wsgi.c - fix "asprintf" call
This commit is contained in:
parent
fe2a607640
commit
ce99f9e734
@ -300,7 +300,9 @@ static PyObject *create_environ(bool tls, int content_length, struct http_header
|
||||
if (!strcasecmp(hdr->name, "Content-Type")) {
|
||||
PyDict_SetItemString(env, "CONTENT_TYPE", PyString_FromString(hdr->value));
|
||||
} else {
|
||||
asprintf(&name, "HTTP_%s", hdr->name);
|
||||
if (asprintf(&name, "HTTP_%s", hdr->name) < 0) {
|
||||
continue;
|
||||
}
|
||||
PyDict_SetItemString(env, name, PyString_FromString(hdr->value));
|
||||
free(name);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user