summaryrefslogtreecommitdiff
path: root/src/stash.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/stash.c')
-rw-r--r--src/stash.c16
1 files changed, 8 insertions, 8 deletions
diff --git a/src/stash.c b/src/stash.c
index 06a7b9a33..458a1e175 100644
--- a/src/stash.c
+++ b/src/stash.c
@@ -440,7 +440,7 @@ static int is_dirty_cb(const char *path, unsigned int status, void *payload)
GIT_UNUSED(status);
GIT_UNUSED(payload);
- return 1;
+ return GIT_PASSTHROUGH;
}
static int ensure_there_are_changes_to_stash(
@@ -463,7 +463,7 @@ static int ensure_there_are_changes_to_stash(
error = git_status_foreach_ext(repo, &opts, is_dirty_cb, NULL);
- if (error == GIT_EUSER)
+ if (error == GIT_PASSTHROUGH)
return 0;
if (!error)
@@ -582,13 +582,13 @@ int git_stash_foreach(
for (i = 0; i < max; i++) {
entry = git_reflog_entry_byindex(reflog, i);
- if (callback(i,
- git_reflog_entry_message(entry),
- git_reflog_entry_id_new(entry),
- payload)) {
- error = giterr_user_cancel();
+ error = GITERR_CALLBACK(
+ callback(i,
+ git_reflog_entry_message(entry),
+ git_reflog_entry_id_new(entry),
+ payload) );
+ if (error)
break;
- }
}
cleanup: