comparison mpegaudiodec.c @ 2647:ac78b35aa838 libavcodec

check for error
author michael
date Thu, 05 May 2005 20:05:41 +0000
parents b7511e7dabb7
children ba8ecddf5598
comparison
equal deleted inserted replaced
2646:c735e3e60ca7 2647:ac78b35aa838
2626 } else { 2626 } else {
2627 out_size = mp_decode_frame(s, out_samples); 2627 out_size = mp_decode_frame(s, out_samples);
2628 } 2628 }
2629 s->inbuf_ptr = s->inbuf; 2629 s->inbuf_ptr = s->inbuf;
2630 s->frame_size = 0; 2630 s->frame_size = 0;
2631 *data_size = out_size; 2631 if(out_size>=0)
2632 *data_size = out_size;
2633 else
2634 av_log(avctx, AV_LOG_DEBUG, "Error while decoding mpeg audio frame\n"); //FIXME return -1 / but also return the number of bytes consumed
2632 break; 2635 break;
2633 } 2636 }
2634 } 2637 }
2635 return buf_ptr - buf; 2638 return buf_ptr - buf;
2636 } 2639 }