git@vger.kernel.org mailing list mirror (one of many)
 help / color / mirror / code / Atom feed
* [PATCH 12/23] transport.c::get_refs_via_curl(): do not leak refs_url
@ 2009-06-05 16:04 Tay Ray Chuan
  2009-06-05 20:46 ` Jakub Narebski
  0 siblings, 1 reply; 4+ messages in thread
From: Tay Ray Chuan @ 2009-06-05 16:04 UTC (permalink / raw)
  To: Git Mailing List; +Cc: Junio C Hamano, Johannes Schindelin, Mike Hommey

From:	Mike Hommey <mh@glandium.org>
Subject: [WIP Patch 02/12] Some cleanup in get_refs_via_curl()
Date:	Sun, 18 Jan 2009 09:04:27 +0100

Signed-off-by: Mike Hommey <mh@glandium.org>
Signed-off-by: Tay Ray Chuan <rctay89@gmail.com>
---
 transport.c |    1 +
 1 files changed, 1 insertions(+), 0 deletions(-)

diff --git a/transport.c b/transport.c
index efecb65..9edd5aa 100644
--- a/transport.c
+++ b/transport.c
@@ -519,6 +519,7 @@ static struct ref *get_refs_via_curl(struct transport *transport, int for_push)
 		free(ref);
 	}

+	free(refs_url);
 	return refs;
 }

--
1.6.3.1

^ permalink raw reply related	[flat|nested] 4+ messages in thread

* Re: [PATCH 12/23] transport.c::get_refs_via_curl(): do not leak refs_url
  2009-06-05 16:04 [PATCH 12/23] transport.c::get_refs_via_curl(): do not leak refs_url Tay Ray Chuan
@ 2009-06-05 20:46 ` Jakub Narebski
  2009-06-06  1:04   ` Tay Ray Chuan
  0 siblings, 1 reply; 4+ messages in thread
From: Jakub Narebski @ 2009-06-05 20:46 UTC (permalink / raw)
  To: Tay Ray Chuan
  Cc: Git Mailing List, Junio C Hamano, Johannes Schindelin,
	Mike Hommey

Tay Ray Chuan <rctay89@gmail.com> writes:

> From:	Mike Hommey <mh@glandium.org>
> Subject: [WIP Patch 02/12] Some cleanup in get_refs_via_curl()

So what is the title of this patch? "transport.c::get_refs_via_curl():
do not leak refs_url" or "Some cleanup in get_refs_via_curl()"?

Perhaps it should be "transport.c: Do not leak refs_url in
get_refs_via_curl()"...?

> Date:	Sun, 18 Jan 2009 09:04:27 +0100
> 
> Signed-off-by: Mike Hommey <mh@glandium.org>
> Signed-off-by: Tay Ray Chuan <rctay89@gmail.com>
> ---
>  transport.c |    1 +
>  1 files changed, 1 insertions(+), 0 deletions(-)
> 
> diff --git a/transport.c b/transport.c
> index efecb65..9edd5aa 100644
> --- a/transport.c
> +++ b/transport.c
> @@ -519,6 +519,7 @@ static struct ref *get_refs_via_curl(struct transport *transport, int for_push)
>  		free(ref);
>  	}
> 
> +	free(refs_url);
>  	return refs;
>  }
> 
> --
> 1.6.3.1
> 

-- 
Jakub Narebski
Poland
ShadeHawk on #git

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [PATCH 12/23] transport.c::get_refs_via_curl(): do not leak  refs_url
  2009-06-05 20:46 ` Jakub Narebski
@ 2009-06-06  1:04   ` Tay Ray Chuan
  0 siblings, 0 replies; 4+ messages in thread
From: Tay Ray Chuan @ 2009-06-06  1:04 UTC (permalink / raw)
  To: Jakub Narebski
  Cc: Git Mailing List, Junio C Hamano, Johannes Schindelin,
	Mike Hommey

Hi,

On Sat, Jun 6, 2009 at 4:46 AM, Jakub Narebski<jnareb@gmail.com> wrote:
>> From: Mike Hommey <mh@glandium.org>
>> Subject: [WIP Patch 02/12] Some cleanup in get_refs_via_curl()
>
> So what is the title of this patch? "transport.c::get_refs_via_curl():
> do not leak refs_url" or "Some cleanup in get_refs_via_curl()"?

See my reply to patch #19.

> Perhaps it should be "transport.c: Do not leak refs_url in
> get_refs_via_curl()"...?

I think it's a matter of preference. I'll put them side-by-side to
demonstrate this better:

transport.c: Do not leak refs_url in get_refs_via_curl()
transport.c::get_refs_via_curl(): do not leak refs_url

There isn't any important difference between the two other than form.

-- 
Cheers,
Ray Chuan

^ permalink raw reply	[flat|nested] 4+ messages in thread

* [PATCH 12/23] transport.c::get_refs_via_curl(): do not leak refs_url
       [not found] <cover.1244277116.git.rctay89@gmail.com>
@ 2009-06-06  8:43 ` Tay Ray Chuan
  0 siblings, 0 replies; 4+ messages in thread
From: Tay Ray Chuan @ 2009-06-06  8:43 UTC (permalink / raw)
  To: Git Mailing List; +Cc: Junio C Hamano, Johannes Schindelin, Mike Hommey

From:	Mike Hommey <mh@glandium.org>

Signed-off-by: Mike Hommey <mh@glandium.org>
Signed-off-by: Tay Ray Chuan <rctay89@gmail.com>
---

This is based on Mike's earlier patch:

Subject: [WIP Patch 02/12] Some cleanup in get_refs_via_curl()
Date:   Sun, 18 Jan 2009 09:04:27 +0100

I've removed the http_cleanup() invocation, after Johannes reported
that it breaks http clone. I've also renamed it, for clarity's sake.

 transport.c |    1 +
 1 files changed, 1 insertions(+), 0 deletions(-)

diff --git a/transport.c b/transport.c
index efecb65..9edd5aa 100644
--- a/transport.c
+++ b/transport.c
@@ -519,6 +519,7 @@ static struct ref *get_refs_via_curl(struct transport *transport, int for_push)
 		free(ref);
 	}

+	free(refs_url);
 	return refs;
 }

--
1.6.3.1

^ permalink raw reply related	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2009-06-06  8:49 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2009-06-05 16:04 [PATCH 12/23] transport.c::get_refs_via_curl(): do not leak refs_url Tay Ray Chuan
2009-06-05 20:46 ` Jakub Narebski
2009-06-06  1:04   ` Tay Ray Chuan
     [not found] <cover.1244277116.git.rctay89@gmail.com>
2009-06-06  8:43 ` Tay Ray Chuan

Code repositories for project(s) associated with this public inbox

	https://80x24.org/mirrors/git.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).