On Mon, Jun 17, 2013 at 06:40:49PM -0700, Brandon Casey wrote:

> From: Brandon Casey <draf...@gmail.com>
> remote_find_tracking() populates the query struct with an allocated
> string in the dst member.  So, we do not need to xstrdup() the string,
> since we can transfer ownership from the query struct (which will go
> out of scope at the end of this function) to our callback struct, but
> we must free the string if it will not be used so we will not leak
> memory.
> Let's do so.

Thanks, looks obviously correct. I wonder if other callers of
remote_find_tracking make the same mistake. It looks like
check_tracking_branch does. And add_branch_for_removal. and
append_ref_to_tracked_list. Yeesh.

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

Reply via email to