git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Johannes Schindelin <Johannes.Schindelin@gmx.de>
To: Frank Lichtenheld <frank@lichtenheld.de>
Cc: Jan Wielemaker <wielemak@science.uva.nl>,
	Martin Langhoff <martin.langhoff@gmail.com>,
	git@vger.kernel.org
Subject: Re: [PATCH/RFT] cvsserver: only allow checkout of branches
Date: Thu, 4 Oct 2007 17:32:19 +0100 (BST)	[thread overview]
Message-ID: <Pine.LNX.4.64.0710041731550.4174@racer.site> (raw)
In-Reply-To: <20071004161812.GA31659@planck.djpig.de>

Hi,

On Thu, 4 Oct 2007, Frank Lichtenheld wrote:

> On Thu, Oct 04, 2007 at 04:29:04PM +0100, Johannes Schindelin wrote:
> > 	Cc'ed Frank, who is de-facto maintainer (according to shortlog) 
> > 	and Martin, who started it all IIRC.
> > 
> > diff --git a/git-cvsserver.perl b/git-cvsserver.perl
> > index 13dbd27..869690c 100755
> > --- a/git-cvsserver.perl
> > +++ b/git-cvsserver.perl
> > @@ -770,6 +770,14 @@ sub req_co
> >  
> >      $log->debug("req_co : " . ( defined($data) ? $data : "[NULL]" ) );
> >  
> > +    if( system("git", "rev-parse", "--verify", "refs/heads/$module" ) != 0 )
> > +    {
> > +	$log->warn("Checkout failed: $module is not a branch");
> > +	print "error 1 Checkout failed: $module is not a branch\n";
> > +	chdir "/";
> > +	exit;
> > +    }
> > +
> >      $log->info("Checking out module '$module' ($state->{CVSROOT}) to '$checkout_path'");
> >  
> >      $ENV{GIT_DIR} = $state->{CVSROOT} . "/";
> 
> Looks good, haven't tested it yet, though. Care to add a testcase
> or should I take care of that?

I would be eternally thankful if you could add the test case, since I am 
really short on time.

Ciao,
Dscho

  reply	other threads:[~2007-10-04 16:32 UTC|newest]

Thread overview: 19+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-10-03 11:48 git-cvsserver commit trouble (unexpected end of file in client) Jan Wielemaker
2007-10-03 13:13 ` Jan Wielemaker
2007-10-03 14:57   ` Jan Wielemaker
2007-10-03 16:11 ` Johannes Schindelin
2007-10-03 18:42   ` Jan Wielemaker
2007-10-03 18:55     ` Johannes Schindelin
     [not found] ` <200710032325.55128.wielemak@science.uva.nl>
     [not found]   ` <Pine.LNX.4.64.0710032311480.28395@racer.site>
2007-10-04  7:27     ` Jan Wielemaker
2007-10-04 11:18       ` git-cvsserver commit trouble BUG+Work-around Jan Wielemaker
2007-10-04 12:56         ` Johannes Schindelin
2007-10-04 13:06           ` Jan Wielemaker
2007-10-04 15:29             ` [PATCH/RFT] cvsserver: only allow checkout of branches Johannes Schindelin
2007-10-04 16:18               ` Frank Lichtenheld
2007-10-04 16:32                 ` Johannes Schindelin [this message]
2007-10-04 17:06               ` Jan Wielemaker
2007-10-04 17:18                 ` Johannes Schindelin
2007-10-04 18:04                 ` Frank Lichtenheld
2007-10-04 21:15               ` Frank Lichtenheld
2007-10-04 21:49                 ` Johannes Schindelin
2007-10-04 21:55                   ` Shawn O. Pearce

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=Pine.LNX.4.64.0710041731550.4174@racer.site \
    --to=johannes.schindelin@gmx.de \
    --cc=frank@lichtenheld.de \
    --cc=git@vger.kernel.org \
    --cc=martin.langhoff@gmail.com \
    --cc=wielemak@science.uva.nl \
    /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).