Fixed warning: ISO C90 forbids mixed declarations and code

This commit is contained in:
Shahram Najm 2013-04-17 14:22:03 +01:00
parent 7d45173851
commit 9f0129fe07
1 changed files with 2 additions and 1 deletions

View File

@ -205,6 +205,7 @@ static int unpack_double(grib_accessor* a, double* val, size_t *len)
size_t n_vals = 0;
size_t size;
unsigned char* decoded = NULL;
unsigned char *p = NULL;
long pos = 0;
long binary_scale_factor = 0;
@ -296,7 +297,7 @@ static int unpack_double(grib_accessor* a, double* val, size_t *len)
pos = 0;
unsigned char *p = decoded;
p = decoded;
for(i = 0; i < n_vals; i++)
{
val[i] = (double) (((grib_decode_unsigned_long(p, &pos, bits8)*bscale)+reference_value)*dscale);