зеркало из https://github.com/microsoft/git.git
git-apply: normalize file mode when comparing with expected value
Sine git only saves the 'x' bit, we shouldn't compare the stat contents directly.
This commit is contained in:
Родитель
940c1bb018
Коммит
de4971b500
1
apply.c
1
apply.c
|
@ -1000,6 +1000,7 @@ static int check_patch(struct patch *patch)
|
|||
}
|
||||
if (patch->is_new < 0)
|
||||
patch->is_new = 0;
|
||||
st.st_mode = ntohl(create_ce_mode(st.st_mode));
|
||||
if (!patch->old_mode)
|
||||
patch->old_mode = st.st_mode;
|
||||
if ((st.st_mode ^ patch->old_mode) & S_IFMT)
|
||||
|
|
Загрузка…
Ссылка в новой задаче