Fix a crash for files with non-multiple of two dimensions.

This commit does fix a crash with this sample: http://totalwebvideo.com/pitchalt.flv. However I've no idea if the fix is really correct. The file might not even be sane for all I know.