[FFmpeg-devel] [PATCH] RTSP alternate protocol 2-3/3

Ronald S. Bultje rsbultje
Sun Mar 2 03:37:10 CET 2008


Hi Michael,

On Sat, Mar 1, 2008 at 7:53 PM, Michael Niedermayer <michaelni at gmx.at>
wrote:

> On Thu, Feb 14, 2008 at 09:01:00AM -0500, Ronald S. Bultje wrote:
> [...]
> > @@ -1075,9 +1079,18 @@
> >          goto fail;
> >      }
> >
> > -    err = make_setup_request(s, host, port, protocol_mask);
> > -    if (err)
> > +    do {
> > +        int protocol = protocol_mask & ~(protocol_mask - 1);
> > +
> > +    err = make_setup_request(s, host, port, protocol);
> > +    if (err < 0)
> >          goto fail;
> > +        protocol_mask &= ~protocol;
> > +        if (protocol_mask == 0 && err == 1) {
> > +            err = AVERROR(EPROTONOSUPPORT);
> > +            goto fail;
> > +        }
> > +    } while (err);
>
> New lines are wrongly indeted.


That's on purpose. I try to make the "reindent" patch as small as possible
so I indent the new lines correctly already and only leave the lines that
this patch does not really touch in the old indent (and then the reindent
patch, 4/4, fixes those lines).

If you'd prefer all lines "wrongly indented" and have the reindent patch fix
that, let me know and I'll submit modified patches.


> Also i suspect this code will leak various things.


make_setup_request() doesn't allocate resources, be that memory or FDs. If
there's something specific that I'm missing, please be more specific. :-).

Ronald




More information about the ffmpeg-devel mailing list