From d83a39554a99802d878e9b36f99e135e288ae2bd Mon Sep 17 00:00:00 2001 From: AlysonStahl-NOAA <166434581+AlysonStahl-NOAA@users.noreply.github.com> Date: Fri, 1 Nov 2024 14:12:09 -0700 Subject: [PATCH] debugging --- wgrib2/unpk.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/wgrib2/unpk.c b/wgrib2/unpk.c index e3054817..c192c7d2 100644 --- a/wgrib2/unpk.c +++ b/wgrib2/unpk.c @@ -252,7 +252,7 @@ int unpk_grib(unsigned char **sec, float *data) { fatal_error("unpk: png decode allocation error", ""); //i = (int) dec_png_clone(sec[7]+5, &width, &height, (unsigned char *) c, &nbits, ndata); - i = (int) g2c_dec_png(sec[7]+5, (int *)&width, (int *)&height, (unsigned char *) c); + i = (int) g2c_dec_png(sec[7]+5, &width, &height, (unsigned char *) c); if (i) fatal_error_i("unpk: png decode error %d",i); mask_pointer = (bitmap_flag == 255) ? NULL : sec[6] + 6; @@ -260,7 +260,7 @@ int unpk_grib(unsigned char **sec, float *data) { if (mask_pointer == NULL) { if (ndata != width*height) - fatal_error_i("png size mismatch w*h=%d", width*height); + fatal_error_i("png size mismatch w*h=%d", ndata); //width*height); } else { if (ndata != width*height + missing_points(mask_pointer, GB2_Sec3_npts(sec)) )