avcodec/cavsdec: Set ret on errors in decode_pic()