patch by Peter Ross, pross xvid org Originally committed as revision 13574 to svn://svn.ffmpeg.org/ffmpeg/trunk