Skip to content

Commit fa811a5

Browse files
committed
Fixing wrong allocation methods in WCS 2.0 GetCoverage.
1 parent ced579e commit fa811a5

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

mapwcs20.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3821,9 +3821,9 @@ static int msWCSGetCoverage20_GetBands(mapObj *map, layerObj *layer,
38213821

38223822
/* If we still don't have band names, use the band names from the coverage metadata */
38233823
if (band_ids == NULL) {
3824-
band_ids = (char**) msSmallCalloc(sizeof(char*), (cm->numbands + 1));
3824+
band_ids = (char**) CPLCalloc(sizeof(char*), (cm->numbands + 1));
38253825
for (i = 0; i < cm->numbands; ++i) {
3826-
band_ids[i] = msStrdup(cm->bands[i].name);
3826+
band_ids[i] = CPLStrdup(cm->bands[i].name);
38273827
}
38283828
}
38293829

0 commit comments

Comments
 (0)