Re: [DRY HUMOR PATCH] Add a few more values for receive.denyCurrentBranch
- From
Jeff King <peff@peff.net>
- Date
- Feb 17, 2009, 01:14 UTC
- Message-ID
- <20090217011424.GA24822@coredump.intra.peff.net>
- In-Reply-To
- <237967ef0902161710k4672e972rdffab0357b8872a8@mail.gmail.com>
On Tue, Feb 17, 2009 at 02:10:33AM +0100, Mikael Magnusson wrote:
Show 15 quoted lines
> 2009/2/17 Jeff King <peff@peff.net>:
> > On Mon, Feb 16, 2009 at 10:52:05PM +0100, Johannes Schindelin wrote:
> >
> >> @@ -75,7 +77,12 @@ static int receive_pack_config(const char *var, const char *value, void *cb)
> >> }
> >>
> >> if (!strcmp(var, "receive.denycurrentbranch")) {
> >> - deny_current_branch = parse_deny_action(var, value);
> >> + if (value && !strcasecmp(value, "updateinstead"))
> >> + deny_current_branch = DENY_UPDATE_INSTEAD;
> >> + else if (value && !strcasecmp(value, "detachinstead"))
> >
> > Config variables are already lower-cased. ;P
>
> But surely the values are not?Heh. Ouch. You are right, of course, and now I have been caught being wrong while making smart-ass comments, so I'll shut up. ;)
-Peff