phoboslab / pl_mpeg

Single file C library for decoding MPEG1 Video and MP2 Audio
799 stars 58 forks source link

Divide-by-zero if macroblock width is zero #4

Closed pcwalton closed 5 years ago

pcwalton commented 5 years ago

AFL found this one. Here's the test case it found.

bad4.mpg.gz

phoboslab commented 5 years ago

Fixed with https://github.com/phoboslab/pl_mpeg/commit/46e24ec11ae30ea3788126e5323952c8fedec963 and https://github.com/phoboslab/pl_mpeg/commit/5fe30d90a8a66de1db8e859747c7f9a09ff4cd65