Re: git checkout creates strange '(null)'-branch
- From
Junio C Hamano <gitster@pobox.com>
- Date
- May 8, 2012, 15:09 UTC
- Message-ID
- <7vaa1izp3h.fsf@alter.siamese.dyndns.org>
- In-Reply-To
- <4FA904C3.7070208@viscovery.net>
Johannes Sixt <j.sixt@viscovery.net> writes:
Show 11 quoted lines
> Am 5/8/2012 13:24, schrieb Erik Faye-Lund: >> + git show-ref | !grep "(null)" > ... >> Now, doing this doesn't make my test above pass, > > It is unlikely to pass if you used this test script literally, because > > $ !grep > !grep: command not found > > "!" is not an operator in a shell script. Insert a space.
Good eyes. Also wouldn't it be a bit pointless to grep for (null) in the first place? It comes only because a particular implementation of vsnprintf() happens to emit it when asked to turn a NULL pointer into a string, and on other platforms it is allowed to segfault.