On Thu, May 22, 2014 at 10:44 AM, Jonathan Nieder wrote:
> Ronnie Sahlberg wrote:
>> On Wed, May 21, 2014 at 6:42 PM, Jonathan Nieder wrote:
>
>>> $ git rev-parse HEAD >.git/refs/heads/foo..bar
>>> $ git branch -m foo..bar something-saner
>>> fatal: Invalid branch name: 'f
Ronnie Sahlberg wrote:
> On Wed, May 21, 2014 at 6:42 PM, Jonathan Nieder wrote:
>> $ git rev-parse HEAD >.git/refs/heads/foo..bar
>> $ git branch -m foo..bar something-saner
>> fatal: Invalid branch name: 'foo..bar'
>>
>> "git branch -m" has an explicit codepath ("recover
On Wed, May 21, 2014 at 6:42 PM, Jonathan Nieder wrote:
> Ronnie Sahlberg wrote:
>> --- a/refs.c
>> +++ b/refs.c
>> @@ -2044,6 +2044,9 @@ static struct ref_lock *lock_ref_sha1_basic(const char
>> *refname,
>> int missing = 0;
>> int attempts_remaining = 3;
>>
>> + if (check_refnam
Ronnie Sahlberg wrote:
> --- a/refs.c
> +++ b/refs.c
> @@ -2044,6 +2044,9 @@ static struct ref_lock *lock_ref_sha1_basic(const char
> *refname,
> int missing = 0;
> int attempts_remaining = 3;
>
> + if (check_refname_format(refname, REFNAME_ALLOW_ONELEVEL))
> + return
Move the check for check_refname_format from lock_any_ref_for_update
to lock_ref_sha1_basic. At some later stage we will get rid of
lock_any_ref_for_update completely.
This leaves lock_any_ref_for_updates as a no-op wrapper which could be removed.
But this wrapper is also called from an external c
5 matches
Mail list logo