Skip to content

Commit acaf81c

Browse files
committed
Fix memory leak in msINLINELayerNextShape() and null pointer dereference in maplexer when rerunning it after msCleanup() (fixes #5558)
1 parent 049a452 commit acaf81c

File tree

6 files changed

+514
-455
lines changed

6 files changed

+514
-455
lines changed

maplayer.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2249,6 +2249,7 @@ int msINLINELayerNextShape(layerObj *layer, shapeObj *shape)
22492249
shape->values = (char **)msSmallRealloc(shape->values, sizeof(char *)*(layer->numitems));
22502250
for (i = shape->numvalues; i < layer->numitems; i++)
22512251
shape->values[i] = msStrdup("");
2252+
shape->numvalues = layer->numitems;
22522253
}
22532254

22542255
break;

0 commit comments

Comments
 (0)