Skip to content

Commit

Permalink
mapuvraster.c: avoid division by zero (CID 1174340)
Browse files Browse the repository at this point in the history
  • Loading branch information
rouault committed May 22, 2021
1 parent 2e4fe66 commit 9bb93e4
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions mapuvraster.c
Expand Up @@ -509,6 +509,8 @@ int msUVRASTERLayerWhichShapes(layerObj *layer, rectObj rect, int isQuery)
if( CSLFetchNameValue( layer->processing, "UV_SPACING" ) != NULL ) {
spacing =
atoi(CSLFetchNameValue( layer->processing, "UV_SPACING" ));
if( spacing == 0 )
spacing = 32;
}

width = (int)(layer->map->width/spacing);
Expand Down

0 comments on commit 9bb93e4

Please sign in to comment.