Re: [PATCH v10 22/44] fetch.c: clear errno before calling functions that might set it

2014-05-27 Thread Ronnie Sahlberg
On Sat, May 17, 2014 at 7:56 AM, Michael Haggerty mhag...@alum.mit.edu wrote: On 05/16/2014 07:37 PM, Ronnie Sahlberg wrote: In s_update_ref there are two calls that when they fail we return an error based on the errno value. In particular we want to return a specific error if ENOTDIR

Re: [PATCH v10 22/44] fetch.c: clear errno before calling functions that might set it

2014-05-17 Thread Michael Haggerty
On 05/16/2014 07:37 PM, Ronnie Sahlberg wrote: In s_update_ref there are two calls that when they fail we return an error based on the errno value. In particular we want to return a specific error if ENOTDIR happened. Both these functions do have failure modes where they may return an error

[PATCH v10 22/44] fetch.c: clear errno before calling functions that might set it

2014-05-16 Thread Ronnie Sahlberg
In s_update_ref there are two calls that when they fail we return an error based on the errno value. In particular we want to return a specific error if ENOTDIR happened. Both these functions do have failure modes where they may return an error without updating errno, in which case a previous and