diff options
Diffstat (limited to 'source3/web/cgi.c')
-rw-r--r-- | source3/web/cgi.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/source3/web/cgi.c b/source3/web/cgi.c index 07a6fbcf54..c6233b0869 100644 --- a/source3/web/cgi.c +++ b/source3/web/cgi.c @@ -164,7 +164,9 @@ void cgi_load_variables(void) open("/dev/null", O_RDWR); if ((s=query_string) || (s=getenv("QUERY_STRING"))) { - for (tok=strtok(s,"&;");tok;tok=strtok(NULL,"&;")) { + char *saveptr; + for (tok=strtok_r(s, "&;", &saveptr); tok; + tok=strtok_r(NULL, "&;", &saveptr)) { p = strchr_m(tok,'='); if (!p) continue; |