From: Brian Gernhardt <benji@silverinsanity.com>
To: git@vger.kernel.org
Subject: [PATCH] Use exit 1 instead of die when req_Root fails.
Date: Wed, 3 Oct 2007 21:43:47 -0400 [thread overview]
Message-ID: <20071004014253.GA22390@Hermes.local> (raw)
In-Reply-To: <20071004011954.GK18024@planck.djpig.de>
This was causing test failures because die was exiting 255.
---
This finally takes care of my test failures.
git-cvsserver.perl | 6 ++++--
1 files changed, 4 insertions(+), 2 deletions(-)
diff --git a/git-cvsserver.perl b/git-cvsserver.perl
index 13dbd27..0d55fec 100755
--- a/git-cvsserver.perl
+++ b/git-cvsserver.perl
@@ -145,8 +145,10 @@ if ($state->{method} eq 'pserver') {
}
my $request = $1;
$line = <STDIN>; chomp $line;
- req_Root('root', $line) # reuse Root
- or die "E Invalid root $line \n";
+ unless (req_Root('root', $line)) { # reuse Root
+ print "E Invalid root $line \n";
+ exit 1;
+ }
$line = <STDIN>; chomp $line;
unless ($line eq 'anonymous') {
print "E Only anonymous user allowed via pserver\n";
--
1.5.3.4.203.gcc61a
next prev parent reply other threads:[~2007-10-04 1:43 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-10-03 19:50 git-cvsserver test failures (still) Brian Gernhardt
2007-10-04 1:19 ` Frank Lichtenheld
2007-10-04 1:43 ` Brian Gernhardt [this message]
-- strict thread matches above, loose matches on Subject: below --
2007-10-17 14:05 [PATCH] Use exit 1 instead of die when req_Root fails Brian Gernhardt
2007-10-17 14:39 ` Morten Welinder
2007-10-17 15:16 ` Brian Gernhardt
2007-10-17 15:39 ` Lars Hjemli
2007-10-17 18:40 ` Brian Gernhardt
2007-10-17 19:27 ` Lars Hjemli
2007-10-18 18:54 ` Jan Hudec
2007-10-17 19:08 ` Frank Lichtenheld
2007-10-17 19:06 ` Frank Lichtenheld
2007-10-17 19:15 ` Brian Gernhardt
2007-10-18 5:04 ` Shawn O. Pearce
2007-10-18 13:33 ` Frank Lichtenheld
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20071004014253.GA22390@Hermes.local \
--to=benji@silverinsanity.com \
--cc=git@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).