mirror of
https://github.com/RfidResearchGroup/proxmark3.git
synced 2025-08-22 06:13:51 -07:00
Fix corruption in first line of Waveshare image
This commit is contained in:
parent
778a129f52
commit
cdcfa63cba
1 changed files with 1 additions and 1 deletions
|
@ -65,7 +65,7 @@ gdImagePtr img_palettize(gdImagePtr rgb, int * palette, int palette_size) {
|
||||||
* Note that we are storing two extra values so we don't have to do boundary checking at
|
* Note that we are storing two extra values so we don't have to do boundary checking at
|
||||||
* the left and right edges of the image.
|
* the left and right edges of the image.
|
||||||
*/
|
*/
|
||||||
struct ycbcr_t * forward = malloc((gdImageSX(rgb) + 2) * sizeof(struct ycbcr_t));
|
struct ycbcr_t * forward = calloc(gdImageSX(rgb) + 2, sizeof(struct ycbcr_t));
|
||||||
if (!forward) {
|
if (!forward) {
|
||||||
free(pal_ycbcr);
|
free(pal_ycbcr);
|
||||||
gdImageDestroy(res);
|
gdImageDestroy(res);
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue