{"thread":{"id":"7746","subject":"[PATCH] pack-objects: remove obsolete comments","startedAt":"2007-04-20T02:28:02Z","lastAt":"2007-04-20T02:28:02Z","messageCount":1,"participants":["Nicolas Pitre"],"isPatch":true,"patchVersion":1,"patchTotal":null},"messages":[{"id":"39935","messageId":"alpine.LFD.0.98.0704192225120.4504@xanadu.home","threadId":"7746","inReplyTo":null,"subject":"[PATCH] pack-objects: remove obsolete comments","fromName":"Nicolas Pitre","fromEmail":"nico@cam.org","sentAt":"2007-04-20T02:28:02Z","receivedAt":"2007-04-20T02:28:02Z","isPatch":true,"sender":{"key":"nico@fluxnic.net","avatar":"https://avatars.githubusercontent.com/u/702790?v=4"},"body":"The sorted-by-sha ans sorted-by-type arrays are no more.\n\nSigned-off-by: Nicolas Pitre <nico@cam.org>\n---\n\ndiff --git a/builtin-pack-objects.c b/builtin-pack-objects.c\nindex 19fae4c..c72e07a 100644\n--- a/builtin-pack-objects.c\n+++ b/builtin-pack-objects.c\n@@ -49,22 +49,15 @@ struct object_entry {\n  * expanded).  nr_objects & nr_alloc controls this array.  They are stored\n  * in the order we see -- typically rev-list --objects order that gives us\n  * nice \"minimum seek\" order.\n- *\n- * sorted-by-sha ans sorted-by-type are arrays of pointers that point at\n- * elements in the objects array.  The former is used to build the pack\n- * index (lists object names in the ascending order to help offset lookup),\n- * and the latter is used to group similar things together by try_delta()\n- * heuristics.\n  */\n+static struct object_entry *objects;\n+static uint32_t nr_objects, nr_alloc, nr_result;\n \n static int non_empty;\n static int no_reuse_delta;\n static int local;\n static int incremental;\n static int allow_ofs_delta;\n-\n-static struct object_entry *objects;\n-static uint32_t nr_objects, nr_alloc, nr_result;\n static const char *pack_tmp_name, *idx_tmp_name;\n static char tmpname[PATH_MAX];\n static unsigned char pack_file_sha1[20];\n@@ -76,8 +69,7 @@ static int num_preferred_base;\n \n /*\n  * The object names in objects array are hashed with this hashtable,\n- * to help looking up the entry by object name.  Binary search from\n- * sorted_by_sha is also possible but this was easier to code and faster.\n+ * to help looking up the entry by object name.\n  * This hashtable is built after all the objects are seen.\n  */\n static int *object_ix;\n"}]}