Patch by Art Clarke (aclarke AT xuggle com) Originally committed as revision 19327 to svn://svn.ffmpeg.org/ffmpeg/trunk