{"thread":{"id":"4105","subject":"(patch) calloc->xcalloc in read-cache.c","startedAt":"2006-05-08T18:01:40Z","lastAt":"2006-05-08T20:54:50Z","messageCount":2,"participants":["Yakov Lerner","Junio C Hamano"],"isPatch":false,"patchVersion":null,"patchTotal":null},"messages":[{"id":"19719","messageId":"f36b08ee0605081101w3dc3a60cof5a524e9b4a3f555@mail.gmail.com","threadId":"4105","inReplyTo":null,"subject":"(patch) calloc->xcalloc in read-cache.c","fromName":"Yakov Lerner","fromEmail":"iler.ml@gmail.com","sentAt":"2006-05-08T18:01:40Z","receivedAt":"2006-05-08T18:01:40Z","isPatch":false,"sender":{"key":"iler.ml@gmail.com","avatar":null},"body":"--- read-cache.c.000    2006-05-08 15:13:57.000000000 +0000\n+++ read-cache.c        2006-05-08 15:15:35.000000000 +0000\n@@ -557,7 +557,7 @@\n\n        active_nr = ntohl(hdr->hdr_entries);\n        active_alloc = alloc_nr(active_nr);\n-       active_cache = calloc(active_alloc, sizeof(struct cache_entry *));\n+       active_cache = xcalloc(active_alloc, sizeof(struct cache_entry *));\n\n        offset = sizeof(*hdr);\n        for (i = 0; i < active_nr; i++) {\n\nYakov\n"},{"id":"19724","messageId":"7vzmhsdyp1.fsf@assigned-by-dhcp.cox.net","threadId":"4105","inReplyTo":"f36b08ee0605081101w3dc3a60cof5a524e9b4a3f555@mail.gmail.com","subject":"Re: (patch) calloc->xcalloc in read-cache.c","fromName":"Junio C Hamano","fromEmail":"junkio@cox.net","sentAt":"2006-05-08T20:54:50Z","receivedAt":"2006-05-08T20:54:50Z","isPatch":false,"sender":{"key":"gitster@pobox.com","avatar":"https://avatars.githubusercontent.com/u/54884?v=4"},"body":"\"Yakov Lerner\" <iler.ml@gmail.com> writes:\n\n> --- read-cache.c.000    2006-05-08 15:13:57.000000000 +0000\n> +++ read-cache.c        2006-05-08 15:15:35.000000000 +0000\n> @@ -557,7 +557,7 @@\n>\n>        active_nr = ntohl(hdr->hdr_entries);\n>        active_alloc = alloc_nr(active_nr);\n> -       active_cache = calloc(active_alloc, sizeof(struct cache_entry *));\n> +       active_cache = xcalloc(active_alloc, sizeof(struct cache_entry *));\n>\n>        offset = sizeof(*hdr);\n>        for (i = 0; i < active_nr; i++) {\n>\n> Yakov\n\nWhile I do not mind hand generated patch, your mailer setting\nseems to be seriously broken.  \n\nMind checking Documentation/SubmittingPatches and try again?\n"}]}