Re: [PATCH] add receive.denyNonFastforwards config variable

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Johannes Schindelin <Johannes.Schindelin@xxxxxx> writes:

> 	No longer barfs on new refs, and tries all merge bases (even if I
> 	cannot come up with any scenario where there is more than one merge
> 	base in the case of a fast forward).

Hmm.  If that is the case (and I think it is although I haven't
come up with a proof), the test can be written like this:

	if (bases && !bases->next &&
            hashcmp(old_sha1, bases->item->object.sha1))
        	; /* happy */
	else
        	return error("not a fast forward");

perhaps?

-
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]