Increase buffer size to prevent potential overflow

This commit is contained in:
MCUdude 2022-03-18 19:17:17 +01:00
parent 34168759b0
commit dcf771424b
1 changed files with 1 additions and 1 deletions

View File

@ -364,7 +364,7 @@ static int cmd_write(PROGRAMMER * pgm, struct avrpart * p,
return -1;
}
uint8_t * buf = malloc(mem->size);
uint8_t * buf = malloc(mem->size + 0x10);
if (buf == NULL) {
avrdude_message(MSG_INFO, "%s (write): out of memory\n", progname);
return -1;