vendor/libgit2/src/checkout.c in rugged-0.26.0b5 vs vendor/libgit2/src/checkout.c in rugged-0.26.0
- old
+ new
@@ -368,14 +368,12 @@
/* for tree entries, we have to see if there are any index
* entries that are contained inside that tree
*/
const git_index_entry *e = git_index_get_byindex(data->index, pos);
- if (e != NULL && data->diff->pfxcomp(e->path, wd->path) == 0) {
- notify = GIT_CHECKOUT_NOTIFY_DIRTY;
- remove = ((data->strategy & GIT_CHECKOUT_FORCE) != 0);
- }
+ if (e != NULL && data->diff->pfxcomp(e->path, wd->path) == 0)
+ return git_iterator_advance_into(wditem, workdir);
}
}
if (notify != GIT_CHECKOUT_NOTIFY_NONE) {
/* if we found something in the index, notify and advance */
@@ -2317,18 +2315,17 @@
git_vector_free_deep(&data->update_conflicts);
git__free(data->pfx);
data->pfx = NULL;
- git_strmap_free(data->mkdir_map);
-
git_buf_free(&data->target_path);
git_buf_free(&data->tmp);
git_index_free(data->index);
data->index = NULL;
git_strmap_free(data->mkdir_map);
+ data->mkdir_map = NULL;
git_attr_session__free(&data->attr_session);
}
static int checkout_data_init(