Re: [PATCH 17/18] Place the open() call inside the do{} struct and prevent failing close

2013-06-06 Thread Célestin Matte
Le 06/06/2013 23:58, Junio C Hamano a écrit : > Célestin Matte writes: > >> So using autodie may not be a good idea. >> But the problem is that in the current state, open() return values are >> checked, but print ones are not, although it should be. > > I tried "man autodie" and tried to spot 'p

Re: [PATCH 17/18] Place the open() call inside the do{} struct and prevent failing close

2013-06-06 Thread Junio C Hamano
Célestin Matte writes: > So using autodie may not be a good idea. > But the problem is that in the current state, open() return values are > checked, but print ones are not, although it should be. I tried "man autodie" and tried to spot 'print' in the categories list that shows things like ":all

Re: [PATCH 17/18] Place the open() call inside the do{} struct and prevent failing close

2013-06-06 Thread Célestin Matte
Le 06/06/2013 23:13, Junio C Hamano a écrit : > Confused. Which part of this patch moves open inside a do{} block? > This was last touched by [9/18] but it doesn't do any such thing, > either. I must have failed the rebase, as the first part of the commit moved to [14/18] because it modifies a pa

Re: [PATCH 17/18] Place the open() call inside the do{} struct and prevent failing close

2013-06-06 Thread Junio C Hamano
Célestin Matte writes: > Placing the open() call inside the do{} struct will automatically close the > filehandle if possible. > Placing the close() call outside the do{} struct is useless and will make it > fail systematically > Change the error message to state that what fails is a fork(), not

[PATCH 17/18] Place the open() call inside the do{} struct and prevent failing close

2013-06-06 Thread Célestin Matte
Placing the open() call inside the do{} struct will automatically close the filehandle if possible. Placing the close() call outside the do{} struct is useless and will make it fail systematically Change the error message to state that what fails is a fork(), not a file opening. Use autodie to prop