Fossil SCM
Minor tweaks prior to merging.
Commit
4231d4b6343d6afbf6a4c3317f4abce461e1584987eac995e1ca0afc2c2b5264
Parent
20c64950a9a1da4…
1 file changed
+4
-2
+4
-2
| --- src/cgi.c | ||
| +++ src/cgi.c | ||
| @@ -493,11 +493,13 @@ | ||
| 493 | 493 | ** zName is the name of the query parameter or cookie and zValue |
| 494 | 494 | ** is its fully decoded value. zName will be modified to be an |
| 495 | 495 | ** all lowercase string. |
| 496 | 496 | ** |
| 497 | 497 | ** zName and zValue are not copied and must not change or be |
| 498 | -** deallocated after this routine returns. | |
| 498 | +** deallocated after this routine returns. This routine changes | |
| 499 | +** all ASCII alphabetic characters in zName to lower case. The | |
| 500 | +** caller must not change them back. | |
| 499 | 501 | */ |
| 500 | 502 | void cgi_set_parameter_nocopy_tolower( |
| 501 | 503 | char *zName, |
| 502 | 504 | const char *zValue, |
| 503 | 505 | int isQP |
| @@ -1040,11 +1042,11 @@ | ||
| 1040 | 1042 | |
| 1041 | 1043 | len = atoi(PD("CONTENT_LENGTH", "0")); |
| 1042 | 1044 | zType = P("CONTENT_TYPE"); |
| 1043 | 1045 | zSemi = zType ? strchr(zType, ';') : 0; |
| 1044 | 1046 | if( zSemi ){ |
| 1045 | - g.zContentType = mprintf("%.*s", zSemi-zType, zType); | |
| 1047 | + g.zContentType = mprintf("%.*s", (int)(zSemi-zType), zType); | |
| 1046 | 1048 | zType = g.zContentType; |
| 1047 | 1049 | }else{ |
| 1048 | 1050 | g.zContentType = zType; |
| 1049 | 1051 | } |
| 1050 | 1052 | blob_zero(&g.cgiIn); |
| 1051 | 1053 |
| --- src/cgi.c | |
| +++ src/cgi.c | |
| @@ -493,11 +493,13 @@ | |
| 493 | ** zName is the name of the query parameter or cookie and zValue |
| 494 | ** is its fully decoded value. zName will be modified to be an |
| 495 | ** all lowercase string. |
| 496 | ** |
| 497 | ** zName and zValue are not copied and must not change or be |
| 498 | ** deallocated after this routine returns. |
| 499 | */ |
| 500 | void cgi_set_parameter_nocopy_tolower( |
| 501 | char *zName, |
| 502 | const char *zValue, |
| 503 | int isQP |
| @@ -1040,11 +1042,11 @@ | |
| 1040 | |
| 1041 | len = atoi(PD("CONTENT_LENGTH", "0")); |
| 1042 | zType = P("CONTENT_TYPE"); |
| 1043 | zSemi = zType ? strchr(zType, ';') : 0; |
| 1044 | if( zSemi ){ |
| 1045 | g.zContentType = mprintf("%.*s", zSemi-zType, zType); |
| 1046 | zType = g.zContentType; |
| 1047 | }else{ |
| 1048 | g.zContentType = zType; |
| 1049 | } |
| 1050 | blob_zero(&g.cgiIn); |
| 1051 |
| --- src/cgi.c | |
| +++ src/cgi.c | |
| @@ -493,11 +493,13 @@ | |
| 493 | ** zName is the name of the query parameter or cookie and zValue |
| 494 | ** is its fully decoded value. zName will be modified to be an |
| 495 | ** all lowercase string. |
| 496 | ** |
| 497 | ** zName and zValue are not copied and must not change or be |
| 498 | ** deallocated after this routine returns. This routine changes |
| 499 | ** all ASCII alphabetic characters in zName to lower case. The |
| 500 | ** caller must not change them back. |
| 501 | */ |
| 502 | void cgi_set_parameter_nocopy_tolower( |
| 503 | char *zName, |
| 504 | const char *zValue, |
| 505 | int isQP |
| @@ -1040,11 +1042,11 @@ | |
| 1042 | |
| 1043 | len = atoi(PD("CONTENT_LENGTH", "0")); |
| 1044 | zType = P("CONTENT_TYPE"); |
| 1045 | zSemi = zType ? strchr(zType, ';') : 0; |
| 1046 | if( zSemi ){ |
| 1047 | g.zContentType = mprintf("%.*s", (int)(zSemi-zType), zType); |
| 1048 | zType = g.zContentType; |
| 1049 | }else{ |
| 1050 | g.zContentType = zType; |
| 1051 | } |
| 1052 | blob_zero(&g.cgiIn); |
| 1053 |