Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on dcvr.yhbt.net X-Spam-Level: X-Spam-ASN: AS31976 209.132.180.0/23 X-Spam-Status: No, score=-4.0 required=3.0 tests=AWL,BAYES_00, HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,RCVD_IN_DNSWL_HI, SPF_HELO_NONE,SPF_NONE shortcircuit=no autolearn=ham autolearn_force=no version=3.4.2 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by dcvr.yhbt.net (Postfix) with ESMTP id 5FD5D1F463 for ; Thu, 12 Sep 2019 14:41:24 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1732592AbfILOlX (ORCPT ); Thu, 12 Sep 2019 10:41:23 -0400 Received: from cloud.peff.net ([104.130.231.41]:47916 "HELO cloud.peff.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with SMTP id S1732512AbfILOlX (ORCPT ); Thu, 12 Sep 2019 10:41:23 -0400 Received: (qmail 13919 invoked by uid 109); 12 Sep 2019 14:41:23 -0000 Received: from Unknown (HELO peff.net) (10.0.1.2) by cloud.peff.net (qpsmtpd/0.94) with SMTP; Thu, 12 Sep 2019 14:41:23 +0000 Authentication-Results: cloud.peff.net; auth=none Received: (qmail 8250 invoked by uid 111); 12 Sep 2019 14:43:22 -0000 Received: from sigill.intra.peff.net (HELO sigill.intra.peff.net) (10.0.0.7) by peff.net (qpsmtpd/0.94) with (TLS_AES_256_GCM_SHA384 encrypted) ESMTPS; Thu, 12 Sep 2019 10:43:22 -0400 Authentication-Results: peff.net; auth=none Date: Thu, 12 Sep 2019 10:41:22 -0400 From: Jeff King To: git@vger.kernel.org Cc: Taylor Blau , Derrick Stolee , =?utf-8?B?Tmd1eeG7hW4gVGjDoWkgTmfhu41j?= Duy Subject: [PATCH v2] upload-pack commit graph segfault fix Message-ID: <20190912144122.GA27815@sigill.intra.peff.net> References: <20190912000414.GA31334@sigill.intra.peff.net> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: <20190912000414.GA31334@sigill.intra.peff.net> Sender: git-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: git@vger.kernel.org Here's a re-roll of my "disable commit graph more gently" fix. Versus v1: - I've included a preparatory patch that speeds up prepare_commit_graph(). It's not strictly related, but there's a textual dependency. It could be easily spun off to its own series. - a comment points out that the ordering of the "disable" check is important - disable_commit_graph() now works on a repository struct - typo fixes in the test comments [1/2]: commit-graph: bump DIE_ON_LOAD check to actual load-time [2/2]: upload-pack: disable commit graph more gently for shallow traversal commit-graph.c | 18 +++++++++++++++--- commit-graph.h | 6 ++++++ repository.h | 3 +++ t/t5500-fetch-pack.sh | 38 ++++++++++++++++++++++++++++++++++++++ upload-pack.c | 2 +- 5 files changed, 63 insertions(+), 4 deletions(-) -Peff