On Mon, Sep 10, 2018 at 09:55:30AM -0700, Junio C Hamano wrote:
> SZEDER Gábor writes:
>
> >>} else {
> >> - options.head_name = xstrdup("detached HEAD");
> >> + free(options.head_name);
> >> + options.head_name = NULL;
> >
> >
SZEDER Gábor writes:
>> } else {
>> -options.head_name = xstrdup("detached HEAD");
>> +free(options.head_name);
>> +options.head_name = NULL;
>
> Please use FREE_AND_NULL(options.head_name) here.
Good; did
On Tue, Sep 04, 2018 at 02:27:20PM -0700, Pratik Karki via GitGitGadget wrote:
> From: Pratik Karki
>
> When running a rebase on a detached HEAD, we currently store the string
> "detached HEAD" in options.head_name. That is a faithful translation of
> the shell script version, and we still kind
From: Pratik Karki
When running a rebase on a detached HEAD, we currently store the string
"detached HEAD" in options.head_name. That is a faithful translation of
the shell script version, and we still kind of need it for the purposes of
the scripted backends.
It is poor style for C, though,
4 matches
Mail list logo