Re: [PATCH 1/5] xfdopen(): if first attempt fails, free memory and try again

2015-03-05 Thread Junio C Hamano
Michael Haggerty writes: > One likely reason for the failure of fdopen() is a lack of free > memory. Interesting. Did you find this by code inspection? Or did you actually hit this issue in real life, and applying this patch helped? The latter would indicate that this failure is rather common

Re: [PATCH 1/5] xfdopen(): if first attempt fails, free memory and try again

2015-03-05 Thread Stefan Beller
On Thu, Mar 5, 2015 at 8:07 AM, Michael Haggerty wrote: > One likely reason for the failure of fdopen() is a lack of free > memory. > > Also expose a new function, fdopen_with_retry(), which retries on > ENOMEM but doesn't die() on errors. In a moment this function will be > used elsewhere. > > Su

[PATCH 1/5] xfdopen(): if first attempt fails, free memory and try again

2015-03-05 Thread Michael Haggerty
One likely reason for the failure of fdopen() is a lack of free memory. Also expose a new function, fdopen_with_retry(), which retries on ENOMEM but doesn't die() on errors. In a moment this function will be used elsewhere. Suggested-by: Jonathan Nieder Signed-off-by: Michael Haggerty --- git-