Add a few size checks when decoding rtjpeg blocks.
Might avoid crashes in unlikely cases, but mostly avoids ugly artefacts
for partial frames.

Originally committed as revision 18925 to svn://svn.ffmpeg.org/ffmpeg/trunk
