From: Ian Jackson Subject: [OSSTEST PATCH] ap-push: Never push an empty revision Date: Wed, 21 Oct 2015 13:52:51 +0100 Message-ID: <1445431971-6797-1-git-send-email-ian.jackson@eu.citrix.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: Received: from mail6.bemta5.messagelabs.com ([195.245.231.135]) by lists.xen.org with esmtp (Exim 4.72) (envelope-from ) id 1Zost4-0005C2-Ok for xen-devel@lists.xenproject.org; Wed, 21 Oct 2015 12:53:02 +0000 List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xen.org Errors-To: xen-devel-bounces@lists.xen.org To: xen-devel@lists.xenproject.org Cc: Ian Jackson , Ian Campbell List-Id: xen-devel@lists.xenproject.org ap-push should not be used to delete the target branch. This safety catch will prevent accidentaly deletion of branches if there is an undetected failure of whatever is generating the revision to push. Signed-off-by: Ian Jackson --- ap-push | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/ap-push b/ap-push index d2195f2..3011561 100755 --- a/ap-push +++ b/ap-push @@ -25,6 +25,10 @@ revision=$2 . ./cri-common select_xenbranch +if [ "x$revision" = x ]; then + echo >&2 "NOT pushing empty revision!"; exit 1 +fi + : ${TAG_LINUX2639:=tested/2.6.39.x} . ./ap-common -- 1.7.10.4