diff --git a/src/plugins/weatherdata/gfs/g2clib/compack.c b/src/plugins/weatherdata/gfs/g2clib/compack.c index 50fb01f64..d58636f49 100644 --- a/src/plugins/weatherdata/gfs/g2clib/compack.c +++ b/src/plugins/weatherdata/gfs/g2clib/compack.c @@ -67,7 +67,7 @@ void compack(g2float *fld,g2int ndpts,g2int idrsnum,g2int *idrstmpl, static g2int zero=0; g2int *ifld,*gref,*glen,*gwidth; g2int *jmin, *jmax, *lbit; - g2int i,j,n,nbits,imin,imax,left; + g2int i,j,n,imin,imax,left; g2int isd,itemp,ilmax,ngwidthref=0,nbitsgwidth=0; g2int nglenref=0,nglenlast=0,iofst,ival1,ival2; g2int minsd,nbitsd=0,maxorig,nbitorig,ngroups; @@ -385,7 +385,6 @@ void compack(g2float *fld,g2int ndpts,g2int idrsnum,g2int *idrstmpl, if ( glen!=0 ) free(glen); } else { // Constant field ( max = min ) - nbits=0; *lcpack=0; nbitsgref=0; ngroups=0; diff --git a/src/plugins/weatherdata/gfs/g2clib/dec_jpeg2000.c b/src/plugins/weatherdata/gfs/g2clib/dec_jpeg2000.c index 8bffbfe2f..4fa926474 100644 --- a/src/plugins/weatherdata/gfs/g2clib/dec_jpeg2000.c +++ b/src/plugins/weatherdata/gfs/g2clib/dec_jpeg2000.c @@ -50,7 +50,6 @@ *$$$*/ { - int ier; g2int i,j,k; jas_image_t *image=0; jas_stream_t *jpcstream; @@ -60,7 +59,6 @@ // jas_init(); - ier=0; // // Create jas_stream_t containing input JPEG200 codestream in memory. // @@ -133,7 +131,7 @@ // Clean up JasPer work structures. // jas_matrix_destroy(data); - ier=jas_stream_close(jpcstream); + jas_stream_close(jpcstream); jas_image_destroy(image); return 0; diff --git a/src/plugins/weatherdata/gfs/g2clib/enc_jpeg2000.c b/src/plugins/weatherdata/gfs/g2clib/enc_jpeg2000.c index 8d0359a33..5c2fb3089 100644 --- a/src/plugins/weatherdata/gfs/g2clib/enc_jpeg2000.c +++ b/src/plugins/weatherdata/gfs/g2clib/enc_jpeg2000.c @@ -167,8 +167,8 @@ int enc_jpeg2000(unsigned char *cin,g2int width,g2int height,g2int nbits, // Clean up JasPer work structures. // rwcnt=jpcstream->rwcnt_; - ier=jas_stream_close(istream); - ier=jas_stream_close(jpcstream); + jas_stream_close(istream); + jas_stream_close(jpcstream); // // Return size of jpeg2000 code stream // diff --git a/src/plugins/weatherdata/gfs/g2clib/enc_png.c b/src/plugins/weatherdata/gfs/g2clib/enc_png.c index c3f75bd4c..96284ef6e 100644 --- a/src/plugins/weatherdata/gfs/g2clib/enc_png.c +++ b/src/plugins/weatherdata/gfs/g2clib/enc_png.c @@ -43,8 +43,6 @@ void user_flush_data(png_structp png_ptr) Dummy Custom flush function */ { - int *do_nothing; - do_nothing=NULL; } diff --git a/src/plugins/weatherdata/gfs/g2clib/g2_addfield.c b/src/plugins/weatherdata/gfs/g2clib/g2_addfield.c index 14a0301b0..a7893a3ec 100644 --- a/src/plugins/weatherdata/gfs/g2clib/g2_addfield.c +++ b/src/plugins/weatherdata/gfs/g2clib/g2_addfield.c @@ -131,10 +131,16 @@ g2int g2_addfield(unsigned char *cgrib,g2int ipdsnum,g2int *ipdstmpl, g2int lensec4,lensec5,lensec6,lensec7; g2int issec3,isprevbmap,lpos3=0,JJ,KK,MM; g2int *coordieee; - g2int width,height,iscan,itemp; + g2int width=0,height=0,iscan=0,itemp=0; g2float *pfld; gtemplate *mappds,*mapdrs; unsigned int allones=4294967295u; + + (void) width; + (void) height; + (void) iscan; + (void) itemp; + (void) allones; ierr=0; // diff --git a/src/plugins/weatherdata/gfs/g2clib/g2_getfld.c b/src/plugins/weatherdata/gfs/g2clib/g2_getfld.c index 2bfb1cfd8..d4935ad9f 100644 --- a/src/plugins/weatherdata/gfs/g2clib/g2_getfld.c +++ b/src/plugins/weatherdata/gfs/g2clib/g2_getfld.c @@ -340,7 +340,6 @@ g2int g2_getfld(unsigned char *cgrib,g2int ifldnum,g2int unpack,g2int expand, break; } // Get length of Section and Section number - iofst=(ipos-1)*8; iofst=ipos*8; gbit(cgrib,&lensec,iofst,32); // Get Length of Section iofst=iofst+32; diff --git a/src/plugins/weatherdata/gfs/g2clib/g2_unpack3.c b/src/plugins/weatherdata/gfs/g2clib/g2_unpack3.c index 0b691127f..2d97bb676 100644 --- a/src/plugins/weatherdata/gfs/g2clib/g2_unpack3.c +++ b/src/plugins/weatherdata/gfs/g2clib/g2_unpack3.c @@ -119,7 +119,6 @@ g2int g2_unpack3(unsigned char *cgrib,g2int *iofst,g2int **igds,g2int **igdstmpl // corresponding entries in array mapgrid. // if (*mapgridlen > 0) { - ligdstmpl=0; ligdstmpl=(g2int *)calloc(*mapgridlen,sizeof(g2int)); if (ligdstmpl == 0) { ierr=6; diff --git a/src/plugins/weatherdata/gfs/g2clib/jpcunpack.c b/src/plugins/weatherdata/gfs/g2clib/jpcunpack.c index d3744ba90..b7790d03b 100644 --- a/src/plugins/weatherdata/gfs/g2clib/jpcunpack.c +++ b/src/plugins/weatherdata/gfs/g2clib/jpcunpack.c @@ -40,7 +40,7 @@ g2int jpcunpack(unsigned char *cpack,g2int len,g2int *idrstmpl,g2int ndpts, { g2int *ifld; - g2int j,nbits,iret; + g2int j,nbits; g2float ref,bscale,dscale; rdieee(idrstmpl+0,&ref,1); @@ -58,7 +58,7 @@ g2int jpcunpack(unsigned char *cpack,g2int len,g2int *idrstmpl,g2int ndpts, fprintf(stderr,"Could not allocate space in jpcunpack.\n Data field NOT upacked.\n"); return(1); } - iret=(g2int)dec_jpeg2000(cpack,len,ifld); + dec_jpeg2000(cpack,len,ifld); for (j=0;j