On 09/30/2014 07:47 PM, Junio C Hamano wrote:
> Jeff King writes:
>
>> On Tue, Sep 30, 2014 at 03:41:55PM +0200, Michael Haggerty wrote:
>>
>>> I didn't fix it because IMO the correct fix is to add a stdio-oriented
>>> entry point to the lockfile API, and teach the lockfile code to handle
>>> clo
On 09/30/2014 07:39 PM, Junio C Hamano wrote:
> Michael Haggerty writes:
>
>> I was being repetitive because I didn't want the docs to depend on the
>> user remembering what the "bss" section is (which, technically, is also
>> not part of the C standard). I think a better way would be to just not
Jeff King writes:
> On Tue, Sep 30, 2014 at 03:41:55PM +0200, Michael Haggerty wrote:
>
>> I didn't fix it because IMO the correct fix is to add a stdio-oriented
>> entry point to the lockfile API, and teach the lockfile code to handle
>> closing the FILE correctly when necessary.
>
> I think so,
Michael Haggerty writes:
> I was being repetitive because I didn't want the docs to depend on the
> user remembering what the "bss" section is (which, technically, is also
> not part of the C standard). I think a better way would be to just not
> mention "bss section" at all and reword the rest.
On Tue, Sep 30, 2014 at 03:41:55PM +0200, Michael Haggerty wrote:
> I didn't fix it because IMO the correct fix is to add a stdio-oriented
> entry point to the lockfile API, and teach the lockfile code to handle
> closing the FILE correctly when necessary.
I think so, too, after our discussion[1]
On 09/26/2014 10:40 PM, Junio C Hamano wrote:
> Michael Haggerty writes:
>
>> +If you need to close the file descriptor you obtained from a
>> +`hold_lock_file_*` function yourself, do so by calling
>> +`close_lock_file`. You should never call `close(2)` yourself!
>
> This is sometimes untenable
On 09/26/2014 08:33 PM, Junio C Hamano wrote:
> Michael Haggerty writes:
>
>> Document a couple more functions and the flags argument as used by
>> hold_lock_file_for_update() and hold_lock_file_for_append().
>> Reorganize the document to make it more accessible.
>>
>> Helped-by: Jonathan Nieder
Michael Haggerty writes:
> +If you need to close the file descriptor you obtained from a
> +`hold_lock_file_*` function yourself, do so by calling
> +`close_lock_file`. You should never call `close(2)` yourself!
This is sometimes untenable, isn't it? A caller may want to
freopen(3) a stream on
Michael Haggerty writes:
> Document a couple more functions and the flags argument as used by
> hold_lock_file_for_update() and hold_lock_file_for_append().
> Reorganize the document to make it more accessible.
>
> Helped-by: Jonathan Nieder
> Signed-off-by: Michael Haggerty
> ---
> Documentat
Document a couple more functions and the flags argument as used by
hold_lock_file_for_update() and hold_lock_file_for_append().
Reorganize the document to make it more accessible.
Helped-by: Jonathan Nieder
Signed-off-by: Michael Haggerty
---
Documentation/technical/api-lockfile.txt | 199 +
10 matches
Mail list logo