From patchwork Sat Apr 13 05:51:28 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jeff King X-Patchwork-Id: 10899295 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id C16D61515 for ; Sat, 13 Apr 2019 05:51:41 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 981D528EA5 for ; Sat, 13 Apr 2019 05:51:41 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 8899528EB3; Sat, 13 Apr 2019 05:51:41 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-7.9 required=2.0 tests=BAYES_00,MAILING_LIST_MULTI, RCVD_IN_DNSWL_HI autolearn=ham version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 3888128EA5 for ; Sat, 13 Apr 2019 05:51:41 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726042AbfDMFva (ORCPT ); Sat, 13 Apr 2019 01:51:30 -0400 Received: from cloud.peff.net ([104.130.231.41]:57158 "HELO cloud.peff.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with SMTP id S1725308AbfDMFva (ORCPT ); Sat, 13 Apr 2019 01:51:30 -0400 Received: (qmail 27670 invoked by uid 109); 13 Apr 2019 05:51:31 -0000 Received: from Unknown (HELO peff.net) (10.0.1.2) by cloud.peff.net (qpsmtpd/0.94) with SMTP; Sat, 13 Apr 2019 05:51:31 +0000 Authentication-Results: cloud.peff.net; auth=none Received: (qmail 12498 invoked by uid 111); 13 Apr 2019 05:51:59 -0000 Received: from sigill.intra.peff.net (HELO sigill.intra.peff.net) (10.0.0.7) by peff.net (qpsmtpd/0.94) with (ECDHE-RSA-AES256-GCM-SHA384 encrypted) SMTP; Sat, 13 Apr 2019 01:51:59 -0400 Authentication-Results: peff.net; auth=none Received: by sigill.intra.peff.net (sSMTP sendmail emulation); Sat, 13 Apr 2019 01:51:28 -0400 Date: Sat, 13 Apr 2019 01:51:28 -0400 From: Jeff King To: git@vger.kernel.org Cc: Jonathan Tan Subject: [PATCH 0/7] some fetch reachability-error fixes Message-ID: <20190413055127.GA32340@sigill.intra.peff.net> MIME-Version: 1.0 Content-Disposition: inline Sender: git-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: git@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP This series fixes a few minor bugs around clients trying to fetch unreachable commits, along with a few associated cleanups. There's a minor conflict in t5516 when merging with next, since that adds GIT_TEST_PROTOCOL_VERSION, causing a few textual conflicts. The resolution should be fairly clear. Where appropriate, I took GIT_TEST_PROTOCOL_VERSION into account so that after merging with next, all tests should still pass even with it set to "2" (well, all the tests that do not already fail on vanilla 'next' with that setting). [1/7]: t5516: drop ok=sigpipe from unreachable-want tests [2/7]: t5530: check protocol response for "not our ref" [3/7]: upload-pack: send ERR packet for non-tip objects [4/7]: pkt-line: prepare buffer before handling ERR packets [5/7]: fetch: use free_refs() [6/7]: remote.c: make singular free_ref() public [7/7]: fetch: do not consider peeled tags as advertised tips fetch-pack.c | 16 +++++++++------- pkt-line.c | 9 +++++---- remote.c | 6 +++--- remote.h | 4 +++- t/t5516-fetch-push.sh | 18 +++++++++++++++--- t/t5530-upload-pack-error.sh | 18 +++++++++++++++--- upload-pack.c | 11 ++++++++--- 7 files changed, 58 insertions(+), 24 deletions(-) -Peff