Re: [PATCH] refs: release strbuf after use in check_refname_component()

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



René Scharfe <l.s.r@xxxxxx> writes:

> Signed-off-by: Rene Scharfe <l.s.r@xxxxxx>
> ---
>  refs.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/refs.c b/refs.c
> index 5fcacc6..ed3b2cb 100644
> --- a/refs.c
> +++ b/refs.c
> @@ -2334,7 +2334,7 @@ static struct ref_lock *lock_ref_sha1_basic(const char *refname,
>  			struct strbuf err = STRBUF_INIT;
>  			unable_to_lock_message(ref_file, errno, &err);
>  			error("%s", err.buf);
> -			strbuf_reset(&err);
> +			strbuf_release(&err);
>  			goto error_return;
>  		}
>  	}

The subject does not seem to match what the patch is doing, but the
patch is obviously correct ;-)

--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]