summaryrefslogtreecommitdiff
path: root/src/stash.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/stash.c')
-rw-r--r--src/stash.c4
1 files changed, 1 insertions, 3 deletions
diff --git a/src/stash.c b/src/stash.c
index 107cbe3ca..edd8c55db 100644
--- a/src/stash.c
+++ b/src/stash.c
@@ -498,9 +498,7 @@ static int reset_index_and_workdir(
git_commit *commit,
bool remove_untracked)
{
- git_checkout_opts opts;
-
- memset(&opts, 0, sizeof(git_checkout_opts));
+ git_checkout_opts opts = GIT_CHECKOUT_OPTS_INIT;
opts.checkout_strategy =
GIT_CHECKOUT_UPDATE_MODIFIED | GIT_CHECKOUT_UPDATE_UNTRACKED;