Return-Path: X-Original-To: apmail-subversion-commits-archive@minotaur.apache.org Delivered-To: apmail-subversion-commits-archive@minotaur.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 897DE18493 for ; Mon, 21 Dec 2015 15:01:30 +0000 (UTC) Received: (qmail 8099 invoked by uid 500); 21 Dec 2015 15:01:30 -0000 Delivered-To: apmail-subversion-commits-archive@subversion.apache.org Received: (qmail 8059 invoked by uid 500); 21 Dec 2015 15:01:30 -0000 Mailing-List: contact commits-help@subversion.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@subversion.apache.org Delivered-To: mailing list commits@subversion.apache.org Received: (qmail 8049 invoked by uid 99); 21 Dec 2015 15:01:30 -0000 Received: from Unknown (HELO spamd4-us-west.apache.org) (209.188.14.142) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 21 Dec 2015 15:01:30 +0000 Received: from localhost (localhost [127.0.0.1]) by spamd4-us-west.apache.org (ASF Mail Server at spamd4-us-west.apache.org) with ESMTP id E576DC0185 for ; Mon, 21 Dec 2015 15:01:29 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at spamd4-us-west.apache.org X-Spam-Flag: NO X-Spam-Score: 0.447 X-Spam-Level: X-Spam-Status: No, score=0.447 tagged_above=-999 required=6.31 tests=[KAM_LAZY_DOMAIN_SECURITY=1, RP_MATCHES_RCVD=-0.554, URIBL_BLOCKED=0.001] autolearn=disabled Received: from mx1-us-west.apache.org ([10.40.0.8]) by localhost (spamd4-us-west.apache.org [10.40.0.11]) (amavisd-new, port 10024) with ESMTP id Sl91G3oteyNK for ; Mon, 21 Dec 2015 15:01:23 +0000 (UTC) Received: from mailrelay1-us-west.apache.org (mailrelay1-us-west.apache.org [209.188.14.139]) by mx1-us-west.apache.org (ASF Mail Server at mx1-us-west.apache.org) with ESMTP id 4A81120FD2 for ; Mon, 21 Dec 2015 15:01:23 +0000 (UTC) Received: from svn01-us-west.apache.org (svn.apache.org [10.41.0.6]) by mailrelay1-us-west.apache.org (ASF Mail Server at mailrelay1-us-west.apache.org) with ESMTP id D6302E0428 for ; Mon, 21 Dec 2015 15:01:22 +0000 (UTC) Received: from svn01-us-west.apache.org (localhost [127.0.0.1]) by svn01-us-west.apache.org (ASF Mail Server at svn01-us-west.apache.org) with ESMTP id D5DBD3A0051 for ; Mon, 21 Dec 2015 15:01:22 +0000 (UTC) Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Subject: svn commit: r1721175 - /subversion/trunk/tools/backup/hot-backup.py.in Date: Mon, 21 Dec 2015 15:01:22 -0000 To: commits@subversion.apache.org From: danielsh@apache.org X-Mailer: svnmailer-1.0.9 Message-Id: <20151221150122.D5DBD3A0051@svn01-us-west.apache.org> Author: danielsh Date: Mon Dec 21 15:01:22 2015 New Revision: 1721175 URL: http://svn.apache.org/viewvc?rev=1721175&view=rev Log: hot-backup.py: Input validation. * tools/backup/hot-backup.py.in: Error out on unknown values. Modified: subversion/trunk/tools/backup/hot-backup.py.in Modified: subversion/trunk/tools/backup/hot-backup.py.in URL: http://svn.apache.org/viewvc/subversion/trunk/tools/backup/hot-backup.py.in?rev=1721175&r1=1721174&r2=1721175&view=diff ============================================================================== --- subversion/trunk/tools/backup/hot-backup.py.in (original) +++ subversion/trunk/tools/backup/hot-backup.py.in Mon Dec 21 15:01:22 2015 @@ -137,6 +137,11 @@ for o, a in opts: usage() sys.exit() +if archive_type not in (None, 'bz2', 'gz', 'zip', 'zip64'): + sys.stderr.write("ERROR: Bad --archive-type\n") + usage(sys.stderr) + sys.exit(2) + if len(args) != 2: sys.stderr.write("ERROR: only two arguments allowed.\n\n") sys.stderr.flush()