From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on dcvr.yhbt.net X-Spam-Level: X-Spam-ASN: AS53758 23.128.96.0/24 X-Spam-Status: No, score=-3.7 required=3.0 tests=AWL,BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,FREEMAIL_FORGED_FROMDOMAIN,FREEMAIL_FROM, HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,RCVD_IN_DNSWL_NONE, SPF_HELO_PASS,SPF_PASS shortcircuit=no autolearn=ham autolearn_force=no version=3.4.2 Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by dcvr.yhbt.net (Postfix) with ESMTP id 4D9931F8C8 for ; Wed, 14 Jul 2021 13:14:41 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S239423AbhGNNPr (ORCPT ); Wed, 14 Jul 2021 09:15:47 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:43562 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S239443AbhGNNPo (ORCPT ); Wed, 14 Jul 2021 09:15:44 -0400 Received: from mail-wm1-x32d.google.com (mail-wm1-x32d.google.com [IPv6:2a00:1450:4864:20::32d]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id D2E80C061768 for ; Wed, 14 Jul 2021 06:12:51 -0700 (PDT) Received: by mail-wm1-x32d.google.com with SMTP id w13so1546262wmc.3 for ; Wed, 14 Jul 2021 06:12:51 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=message-id:in-reply-to:references:from:date:subject:fcc :content-transfer-encoding:mime-version:to:cc; bh=Ss7oOy6Yj3YNaOJhe7iENLeB4Bq6OmgltqDZywOCjk4=; b=Isxg+zHz7ObQ3MCuC9mM1gJUJW33HgQ9JP7ddTK+phb0nBBuCXN5oiBfHvxbCh9AP+ nVRtS5AnBatFd7+Bj+JSogJ6ffUxXZzoRDPeiwmRm335dQ2m4/vM/lgKvDCQfJSzFHhs QemMANcPoWdgtkbhwKKIf/0QapvPXFpwq2WjKex4I7w/ur2Ibra3v4cs/Is/nx/mDdcj vbaWpeuCOatKYpthKPZksp56pBDuUg1LYHojEa5gkrMobE6BQCA5UMIIN4qk2VRBuLJj O311uKsPTmVx9UgHcViEruVDPvPuR/+YgGreAYwEskTGOll/AUuEn5h/V4gYiQjaYJxv jr8g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:message-id:in-reply-to:references:from:date :subject:fcc:content-transfer-encoding:mime-version:to:cc; bh=Ss7oOy6Yj3YNaOJhe7iENLeB4Bq6OmgltqDZywOCjk4=; b=dySil5QBwfyms3Be8SjUT78S1sGlBvOLqAaed2onbb+JP3D6qex3wcJDQorhqrlok1 IRJTzcpSH6D1oN3JRW+XFxctdYIT0axj1x67seOXN15MYfbuO6kiL+PvHABnViITcpuR 3/0nK166yrso8h9mD/4ycFtlExCdhfi5DZE8wyWiznFwGYhQC3ggRCgJB9T2zIV/RF5N HOmio34ryPCjRZI3mb82tmN6QFIbALwlusULJIB/9j4tYBzBsE8HIVt48jJmld7tbL2s CRMOt75Bkwv340nZy5y8m/izJkXyAwyaHX+rV3B38tTOXClm12w3wlZUgTv+KuUIPIyw 28yQ== X-Gm-Message-State: AOAM532ZqHMCewf08CScDHyTDxSHEhb7txquunQTE+yaKkOkWjG0z+hJ 5I75864G/G0yRx6+/0yyWLgfuHA1EvI= X-Google-Smtp-Source: ABdhPJyWdWQ1kPaO/4alkIIEyCkHId20WXmYqc9QBAr4POGIzILB/6IsD9wwcFCTpXziIJ4Km9w3lA== X-Received: by 2002:a05:600c:a04:: with SMTP id z4mr10901712wmp.103.1626268367897; Wed, 14 Jul 2021 06:12:47 -0700 (PDT) Received: from [127.0.0.1] ([13.74.141.28]) by smtp.gmail.com with ESMTPSA id p11sm2449242wro.78.2021.07.14.06.12.47 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 14 Jul 2021 06:12:47 -0700 (PDT) Message-Id: <0e4b7390f478e89d20e33894b69567e489d69c9b.1626268360.git.gitgitgadget@gmail.com> In-Reply-To: References: From: "Derrick Stolee via GitGitGadget" Date: Wed, 14 Jul 2021 13:12:32 +0000 Subject: [PATCH v9 08/16] unpack-trees: rename unpack_nondirectories() Fcc: Sent Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit MIME-Version: 1.0 To: git@vger.kernel.org Cc: gitster@pobox.com, newren@gmail.com, Matheus Tavares Bernardino , Derrick Stolee , git@jeffhostetler.com, johannes.schindelin@gmx.de, Bagas Sanjaya , Derrick Stolee , Derrick Stolee Precedence: bulk List-ID: X-Mailing-List: git@vger.kernel.org From: Derrick Stolee In the next change, we will use this method to unpack a sparse directory entry, so change the name to unpack_single_entry() so these entries apply. The new name reflects that we will not recurse into trees in order to resolve the conflicts. Reviewed-by: Elijah Newren Signed-off-by: Derrick Stolee --- unpack-trees.c | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/unpack-trees.c b/unpack-trees.c index b113cc750f2..d26386ce8b2 100644 --- a/unpack-trees.c +++ b/unpack-trees.c @@ -804,7 +804,7 @@ static int traverse_by_cache_tree(int pos, int nr_entries, int nr_names, BUG("We need cache-tree to do this optimization"); /* - * Do what unpack_callback() and unpack_nondirectories() normally + * Do what unpack_callback() and unpack_single_entry() normally * do. But we walk all paths in an iterative loop instead. * * D/F conflicts and higher stage entries are not a concern @@ -1075,11 +1075,11 @@ static struct cache_entry *create_ce_entry(const struct traverse_info *info, * without actually calling it. If you change the logic here you may need to * check and change there as well. */ -static int unpack_nondirectories(int n, unsigned long mask, - unsigned long dirmask, - struct cache_entry **src, - const struct name_entry *names, - const struct traverse_info *info) +static int unpack_single_entry(int n, unsigned long mask, + unsigned long dirmask, + struct cache_entry **src, + const struct name_entry *names, + const struct traverse_info *info) { int i; struct unpack_trees_options *o = info->data; @@ -1322,7 +1322,7 @@ static int unpack_callback(int n, unsigned long mask, unsigned long dirmask, str } } - if (unpack_nondirectories(n, mask, dirmask, src, names, info) < 0) + if (unpack_single_entry(n, mask, dirmask, src, names, info) < 0) return -1; if (o->merge && src[0]) { -- gitgitgadget