chg: converting some more malloc calls -> calloc

This commit is contained in:
iceman1001 2018-05-03 19:45:59 +02:00
commit faa6ece881
3 changed files with 4 additions and 4 deletions

View file

@ -134,7 +134,7 @@ int zlib_compress(FILE *infile[], uint8_t num_infiles, FILE *outfile, bool hardn
// estimate the size of the compressed output
uint32_t outsize_max = deflateBound(&compressed_fpga_stream, compressed_fpga_stream.avail_in);
uint8_t *outbuf = malloc(outsize_max);
uint8_t *outbuf = calloc(outsize_max, sizeof(uint8_t));
compressed_fpga_stream.next_out = outbuf;
compressed_fpga_stream.avail_out = outsize_max;