Corrected an unlikely but possible passage of a null pointer to memcpy.
@@ -1290,8 +1290,10 @@ nc4_get_vara(NC *nc, int ncid, int varid, const size_t *startp,
} else {
*(char **)filldata = NULL;
}
- } else
+ } else {
+ if(fillvalue)
memcpy(filldata, fillvalue, file_type_size);
+ }
filldata = (char *)filldata + file_type_size;
}
}
