[FFmpeg-devel] [PATCH 4/4] Make file_open() return the error code set in errno if open() fails, rather than alwasy ENOENT.

Michael Niedermayer michaelni
Mon Apr 26 23:49:08 CEST 2010


On Mon, Apr 26, 2010 at 11:40:02PM +0200, Stefano Sabatini wrote:
> On date Monday 2010-04-26 01:16:39 +0200, Stefano Sabatini encoded:
> > ---
> >  libavformat/file.c |    2 +-
> >  1 files changed, 1 insertions(+), 1 deletions(-)
> > 
> > diff --git a/libavformat/file.c b/libavformat/file.c
> > index d42a678..8873d5f 100644
> > --- a/libavformat/file.c
> > +++ b/libavformat/file.c
> > @@ -53,7 +53,7 @@ static int file_open(URLContext *h, const char *filename, int flags)
> >  #endif
> >      fd = open(filename, access, 0666);
> >      if (fd == -1)
> > -        return AVERROR(ENOENT);
> > +        return AVERROR(errno);
> >      h->priv_data = (void *) (intptr_t) fd;
> >      return 0;
> >  }
> 
> Ping.

it does look ok, i hope it wont have the sideeffects of your last
errno patch (issue1894)


[..]
-- 
Michael     GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB

Opposition brings concord. Out of discord comes the fairest harmony.
-- Heraclitus
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: Digital signature
URL: <http://lists.mplayerhq.hu/pipermail/ffmpeg-devel/attachments/20100426/6aacf42a/attachment.pgp>



More information about the ffmpeg-devel mailing list