{"thread":{"id":"9328","subject":"[PATCH 1/4] Fix allocation of \"int*\" instead of \"int\".","startedAt":"2007-07-31T12:48:29Z","lastAt":"2007-08-01T04:11:14Z","messageCount":3,"participants":["Christian Couder","Jeff King"],"isPatch":true,"patchVersion":1,"patchTotal":4},"messages":[{"id":"49217","messageId":"20070731144829.ea83d43d.chriscool@tuxfamily.org","threadId":"9328","inReplyTo":null,"subject":"[PATCH 1/4] Fix allocation of \"int*\" instead of \"int\".","fromName":"Christian Couder","fromEmail":"chriscool@tuxfamily.org","sentAt":"2007-07-31T12:48:29Z","receivedAt":"2007-07-31T12:48:29Z","isPatch":true,"sender":{"key":"christian.couder@gmail.com","avatar":"https://avatars.githubusercontent.com/u/208954?v=4"},"body":"Signed-off-by: Christian Couder <chriscool@tuxfamily.org>\n---\n\n While working on something like a \"git bisect dunno\", I came up with\n the patches in this series.\n\n Thanks in advance,\n Christian.\n\n builtin-rev-list.c |    2 +-\n 1 files changed, 1 insertions(+), 1 deletions(-)\n\ndiff --git a/builtin-rev-list.c b/builtin-rev-list.c\nindex 8efd609..5bcafe4 100644\n--- a/builtin-rev-list.c\n+++ b/builtin-rev-list.c\n@@ -300,7 +300,7 @@ static struct commit_list *find_bisection(struct commit_list *list,\n \tshow_list(\"bisection 2 sorted\", 0, nr, list);\n \n \t*all = nr;\n-\tweights = xcalloc(on_list, sizeof(int*));\n+\tweights = xcalloc(on_list, sizeof(int));\n \tcounted = 0;\n \n \tfor (n = 0, p = list; p; p = p->next) {\n-- \n1.5.2.1.144.gabc40\n"},{"id":"49242","messageId":"20070731195616.GA6329@sigill.intra.peff.net","threadId":"9328","inReplyTo":"20070731144829.ea83d43d.chriscool@tuxfamily.org","subject":"Re: [PATCH 1/4] Fix allocation of \"int*\" instead of \"int\".","fromName":"Jeff King","fromEmail":"peff@peff.net","sentAt":"2007-07-31T19:56:16Z","receivedAt":"2007-07-31T19:56:16Z","isPatch":true,"sender":{"key":"peff@peff.net","avatar":"https://avatars.githubusercontent.com/u/45925?v=4"},"body":"On Tue, Jul 31, 2007 at 02:48:29PM +0200, Christian Couder wrote:\n\n> -\tweights = xcalloc(on_list, sizeof(int*));\n> +\tweights = xcalloc(on_list, sizeof(int));\n\nHow about the correct-by-definition sizeof(*weights)?\n\n-Peff\n"},{"id":"49276","messageId":"200708010611.14171.chriscool@tuxfamily.org","threadId":"9328","inReplyTo":"20070731195616.GA6329@sigill.intra.peff.net","subject":"Re: [PATCH 1/4] Fix allocation of \"int*\" instead of \"int\".","fromName":"Christian Couder","fromEmail":"chriscool@tuxfamily.org","sentAt":"2007-08-01T04:11:14Z","receivedAt":"2007-08-01T04:11:14Z","isPatch":true,"sender":{"key":"christian.couder@gmail.com","avatar":"https://avatars.githubusercontent.com/u/208954?v=4"},"body":"Le mardi 31 juillet 2007 21:56, Jeff King a écrit :\n> On Tue, Jul 31, 2007 at 02:48:29PM +0200, Christian Couder wrote:\n> > -\tweights = xcalloc(on_list, sizeof(int*));\n> > +\tweights = xcalloc(on_list, sizeof(int));\n>\n> How about the correct-by-definition sizeof(*weights)?\n\nThat's ok for me too.\n\nThanks,\nChristian.\n"}]}