1
0
Fork 0
mirror of https://github.com/git/git.git synced 2024-05-09 12:36:08 +02:00
This commit is contained in:
Issam Maghni 2024-04-25 23:18:25 +00:00 committed by GitHub
commit 9883f02bee
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -37,7 +37,7 @@ if [ -z "$GIT_DIR" ]; then
exit 1
fi
if [ -z "$refname" -o -z "$oldrev" -o -z "$newrev" ]; then
if [ -z "$refname" ] || [ -z "$oldrev" ] || [ -z "$newrev" ]; then
echo "usage: $0 <ref> <oldrev> <newrev>" >&2
exit 1
fi
@ -95,7 +95,7 @@ case "$refname","$newrev_type" in
;;
refs/heads/*,commit)
# branch
if [ "$oldrev" = "$zero" -a "$denycreatebranch" = "true" ]; then
if [ "$oldrev" = "$zero" ] && [ "$denycreatebranch" = "true" ]; then
echo "*** Creating a branch is not allowed in this repository" >&2
exit 1
fi