heap corruption due to buffer overrun when initializing txbuffer; incorrect size

This commit is contained in:
ziggurat29 2016-04-20 20:23:01 -05:00
parent 7c8a23371d
commit 5d61e3d6eb

View File

@ -194,7 +194,7 @@ int media_main(int argc, char *argv[])
/* Fill buffer with a (possibly) unique pattern */
for (i = 0; i < info.nblocks; i++)
for (i = 0; i < info.blocksize; i++)
{
txbuffer[i] = value;
if (++value >= END_VALUE)
@ -343,7 +343,7 @@ int media_main(int argc, char *argv[])
/* Fill buffer with a (possibly) unique pattern */
for (i = 0; i < info.nblocks; i++)
for (i = 0; i < info.blocksize; i++)
{
txbuffer[i] = value;
if (++value >= END_VALUE)