{"thread":{"id":"19924","subject":"[PATCH] git-remote: fixed missing .uploadpack usage for show command","startedAt":"2009-06-25T09:00:36Z","lastAt":"2009-06-25T21:48:48Z","messageCount":4,"participants":["Chris Frey","Junio C Hamano"],"isPatch":true,"patchVersion":1,"patchTotal":null},"messages":[{"id":"116909","messageId":"20090625090036.GA32650@foursquare.net","threadId":"19924","inReplyTo":null,"subject":"[PATCH] git-remote: fixed missing .uploadpack usage for show command","fromName":"Chris Frey","fromEmail":"cdfrey@foursquare.net","sentAt":"2009-06-25T09:00:36Z","receivedAt":"2009-06-25T09:00:36Z","isPatch":true,"sender":{"key":"cdfrey@foursquare.net","avatar":null},"body":"When using 'git remote show <name>', the remote HEAD check\ndid not use the uploadpack configuration setting.\n\nSigned-off-by: Chris Frey <cdfrey@foursquare.net>\n---\n builtin-remote.c |    2 +-\n 1 files changed, 1 insertions(+), 1 deletions(-)\n\ndiff --git a/builtin-remote.c b/builtin-remote.c\nindex 658d578..ec1f903 100644\n--- a/builtin-remote.c\n+++ b/builtin-remote.c\n@@ -787,7 +787,7 @@ static int get_remote_ref_states(const char *name,\n \tread_branches();\n \n \tif (query) {\n-\t\ttransport = transport_get(NULL, states->remote->url_nr > 0 ?\n+\t\ttransport = transport_get(states->remote, states->remote->url_nr > 0 ?\n \t\t\tstates->remote->url[0] : NULL);\n \t\tremote_refs = transport_get_remote_refs(transport);\n \t\ttransport_disconnect(transport);\n-- \n1.6.2.5\n"},{"id":"116952","messageId":"7vmy7wcgge.fsf@alter.siamese.dyndns.org","threadId":"19924","inReplyTo":"20090625090036.GA32650@foursquare.net","subject":"Re: [PATCH] git-remote: fixed missing .uploadpack usage for show command","fromName":"Junio C Hamano","fromEmail":"gitster@pobox.com","sentAt":"2009-06-25T18:32:17Z","receivedAt":"2009-06-25T18:32:17Z","isPatch":true,"sender":{"key":"gitster@pobox.com","avatar":"https://avatars.githubusercontent.com/u/54884?v=4"},"body":"Chris Frey <cdfrey@foursquare.net> writes:\n\n> When using 'git remote show <name>', the remote HEAD check\n> did not use the uploadpack configuration setting.\n>\n> Signed-off-by: Chris Frey <cdfrey@foursquare.net>\n\nThanks.\n\n\"X did not use Y\" may be a good statement of the fact.  From the patch\ntext it can be seen that a NULL used to be passed and the patch makes it\nto pass states->remote instead, so \"This patch make X use Y\", even though\nleft unsaid in the message, can be seen.\n\nBut it does not answer a more important question.  How was it a problem\nthat \"X did not use Y\"?\n\nPeople who followed a recent discussion know the answer to this question,\nbut ones who read this in the \"git log\" output 6 months down the line will\nnot.  Please make a habit of justifying the change by stating \"why\".\n\n\"X should have used Y because of such and such reasons, but it didn't.\nInstead of showing the correct result W, it gave Z, which may happen to be\nthe same as W in default settings but otherwise is wrong.\"\n"},{"id":"116968","messageId":"20090625212135.GA28935@foursquare.net","threadId":"19924","inReplyTo":"7vmy7wcgge.fsf@alter.siamese.dyndns.org","subject":"[PATCH] git-remote: fixed missing .uploadpack usage for show command","fromName":"Chris Frey","fromEmail":"cdfrey@foursquare.net","sentAt":"2009-06-25T21:21:35Z","receivedAt":"2009-06-25T21:21:35Z","isPatch":true,"sender":{"key":"cdfrey@foursquare.net","avatar":null},"body":"For users pulling from machines with self compiled git installs,\nin non-PATH locations, they can set the config option\nremote.<name>.uploadpack to set the location of git-upload-pack.\n\nWhen using 'git remote show <name>', the remote HEAD check\ndid not use the uploadpack configuration setting, and would stall.\n\nIn builtin-remote.c, the config setting is already loaded\nwith the call to remote_get(), so this patch passes that remote\nalong to transport_get().\n\nSigned-off-by: Chris Frey <cdfrey@foursquare.net>\n---\n\nA possibly clearer description...\n\n\n builtin-remote.c |    2 +-\n 1 files changed, 1 insertions(+), 1 deletions(-)\n\ndiff --git a/builtin-remote.c b/builtin-remote.c\nindex 658d578..ec1f903 100644\n--- a/builtin-remote.c\n+++ b/builtin-remote.c\n@@ -787,7 +787,7 @@ static int get_remote_ref_states(const char *name,\n \tread_branches();\n \n \tif (query) {\n-\t\ttransport = transport_get(NULL, states->remote->url_nr > 0 ?\n+\t\ttransport = transport_get(states->remote, states->remote->url_nr > 0 ?\n \t\t\tstates->remote->url[0] : NULL);\n \t\tremote_refs = transport_get_remote_refs(transport);\n \t\ttransport_disconnect(transport);\n-- \n1.6.2.5\n"},{"id":"116969","messageId":"7vd48s2ddr.fsf@alter.siamese.dyndns.org","threadId":"19924","inReplyTo":"20090625212135.GA28935@foursquare.net","subject":"Re: [PATCH] git-remote: fix missing .uploadpack usage for show command","fromName":"Junio C Hamano","fromEmail":"gitster@pobox.com","sentAt":"2009-06-25T21:48:48Z","receivedAt":"2009-06-25T21:48:48Z","isPatch":true,"sender":{"key":"gitster@pobox.com","avatar":"https://avatars.githubusercontent.com/u/54884?v=4"},"body":"Chris Frey <cdfrey@foursquare.net> writes:\n\n> For users pulling from machines with self compiled git installs,\n> in non-PATH locations, they can set the config option\n> remote.<name>.uploadpack to set the location of git-upload-pack.\n>\n> When using 'git remote show <name>', the remote HEAD check\n> did not use the uploadpack configuration setting, and would\n> not use the configured program.\n>\n> In builtin-remote.c, the config setting is already loaded\n> with the call to remote_get(), so this patch passes that remote\n> along to transport_get().\n>\n> Signed-off-by: Chris Frey <cdfrey@foursquare.net>\n> ---\n>\n> A possibly clearer description...\n\nThanks, much clearer.  Will queue, aiming to eventually merge to 'maint'.\n\nDo you have tests to protect this fix from getting broken in the future by\nother people?\n"}]}