Skip to content

Commit

Permalink
core/pixelmap/util: check width/height >0 in BrPixelmapResizeBuffersTV()
Browse files Browse the repository at this point in the history
  • Loading branch information
vs49688 committed Sep 28, 2024
1 parent 5e09525 commit 2546f86
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions core/pixelmap/pmutil.c
Original file line number Diff line number Diff line change
Expand Up @@ -101,6 +101,9 @@ br_error BrPixelmapResizeBuffersTV(br_pixelmap *screen, br_pixelmap **colour, br
}
}

if(target_width <= 0 || target_height <= 0)
return BRE_FAIL;

if(target_depth_bits < 16)
target_depth_bits = 16;

Expand Down

0 comments on commit 2546f86

Please sign in to comment.