[FFmpeg-devel] [patch]add mmsh protocol and extract common code for mmst.c

Ronald S. Bultje rsbultje
Fri Aug 13 16:28:25 CEST 2010


Hi,

On Thu, Aug 12, 2010 at 9:21 PM, zhentan feng <spyfeng at gmail.com> wrote:
> On Fri, Aug 13, 2010 at 6:00 AM, Ronald S. Bultje <rsbultje at gmail.com>wrote:
>> > + ? ? ? ?} else {
>> > + ? ? ? ? ? ?if (len) {
>> > + ? ? ? ? ? ? ? ?if (len > sizeof(mms->in_buffer)) {
>> > + ? ? ? ? ? ? ? ? ? ?av_log(NULL, AV_LOG_ERROR, "other packet len = %d
>> exceed the in_buffer size %d\n",
>> > + ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ?len, sizeof(mms->in_buffer));
>> > + ? ? ? ? ? ? ? ? ? ?return AVERROR_IO;
>> > + ? ? ? ? ? ? ? ?}
>> > + ? ? ? ? ? ? ? ?res = url_read_complete(mms->mms_hd, mms->in_buffer,
>> len);
>> > + ? ? ? ? ? ? ? ?if (res != len) {
>> > + ? ? ? ? ? ? ? ? ? ?av_log(NULL, AV_LOG_ERROR, "read other chunk type
>> data failed!\n");
>> > + ? ? ? ? ? ? ? ? ? ?return AVERROR(EIO);
>> > + ? ? ? ? ? ? ? ?} else {
>> > + ? ? ? ? ? ? ? ? ? ?dprintf(NULL, "skip chunk type %d \n", chunk_type);
>> > + ? ? ? ? ? ? ? ? ? ?continue;
>> > + ? ? ? ? ? ? ? ?}
>> > + ? ? ? ? ? ?}
>> > + ? ? ? ?}
>>
>> Did you try using url_fskip() here, as suggested earlier?
>
> I am sorry. I didn't try it.
> But I was considering that if use url_fskip(ByteIOContext *s, int64_t

Oh right, I see. Nevermind this comment then.

Ronald



More information about the ffmpeg-devel mailing list