MCPcopy Index your code
hub / github.com/MapServer/MapServer / cgirequestObj_setParameter

Function cgirequestObj_setParameter

mapscript/php/mapscript_i.c:1472–1492  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1470
1471
1472void cgirequestObj_setParameter(cgiRequestObj *self, char *name, char *value)
1473{
1474 int i;
1475
1476 if (self->NumParams == MS_DEFAULT_CGI_PARAMS) {
1477 msSetError(MS_CHILDERR, "Maximum number of items, %d, has been reached", "setItem()", MS_DEFAULT_CGI_PARAMS);
1478 }
1479
1480 for (i=0; i<self->NumParams; i++) {
1481 if (strcasecmp(self->ParamNames[i], name) == 0) {
1482 free(self->ParamValues[i]);
1483 self->ParamValues[i] = strdup(value);
1484 break;
1485 }
1486 }
1487 if (i == self->NumParams) {
1488 self->ParamNames[self->NumParams] = strdup(name);
1489 self->ParamValues[self->NumParams] = strdup(value);
1490 self->NumParams++;
1491 }
1492}
1493
1494char *cgirequestObj_getName(cgiRequestObj *self, int index)
1495{

Callers 1

owsrequest.cFile · 0.85

Calls 3

msSetErrorFunction · 0.85
strcasecmpFunction · 0.85
strdupFunction · 0.85

Tested by

no test coverage detected