317 NSAPI_PUBLIC char* util_uri_strip_params(char *uri) |
317 NSAPI_PUBLIC char* util_uri_strip_params(char *uri) |
318 { |
318 { |
319 // As per RFC2396, URI path segments can contain parameters beginning with |
319 // As per RFC2396, URI path segments can contain parameters beginning with |
320 // ';'. These parameters must be removed from the ppath. Bug 418271 |
320 // ';'. These parameters must be removed from the ppath. Bug 418271 |
321 char* out; |
321 char* out; |
322 if (out = strchr(uri, ';')) { |
322 if((out = strchr(uri, ';'))) { |
323 char* in = out; |
323 char* in = out; |
324 while (*in) { |
324 while (*in) { |
325 if (*in == ';') { |
325 if (*in == ';') { |
326 // Skip past parameter |
326 // Skip past parameter |
327 do in++; while (*in && *in != '/'); |
327 do in++; while (*in && *in != '/'); |