X-Git-Url: https://git.tokkee.org/?a=blobdiff_plain;f=entry.c;h=004182c99d27a6a5825d2429f9104fc7a8f1dc80;hb=1cef6500a9edc7997bd0aa4cd1f739f5106ab0a9;hp=06d24f14c6ba9401637aebfb11659ae747796c06;hpb=814035c12a07927ea03350184a14f869cdce7276;p=git.git diff --git a/entry.c b/entry.c index 06d24f14c..004182c99 100644 --- a/entry.c +++ b/entry.c @@ -179,7 +179,7 @@ static int write_entry(struct cache_entry *ce, char *path, const struct checkout * This is like 'lstat()', except it refuses to follow symlinks * in the path, after skipping "skiplen". */ -int check_path(const char *path, int len, struct stat *st, int skiplen) +static int check_path(const char *path, int len, struct stat *st, int skiplen) { const char *slash = path + len; @@ -206,7 +206,7 @@ int checkout_entry(struct cache_entry *ce, const struct checkout *state, char *t len += ce_namelen(ce); if (!check_path(path, len, &st, state->base_dir_len)) { - unsigned changed = ce_match_stat(ce, &st, CE_MATCH_IGNORE_VALID); + unsigned changed = ce_match_stat(ce, &st, CE_MATCH_IGNORE_VALID|CE_MATCH_IGNORE_SKIP_WORKTREE); if (!changed) return 0; if (!state->force) {