diff options
author | René Scharfe <l.s.r@web.de> | 2020-10-24 19:06:48 +0200 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2020-11-01 15:51:31 -0800 |
commit | 4f44c5659bfb6e80fe76e68ec775859915d5f94a (patch) | |
tree | c9a17eecc5ad1272139f3e991b20a64547757d55 /builtin/config.c | |
parent | Git 2.29.2 (diff) | |
download | tgif-4f44c5659bfb6e80fe76e68ec775859915d5f94a.tar.xz |
stash: simplify reflog emptiness check
Calling rev-parse to check if the drop subcommand removed the last stash
and treating its failure as confirmation is fragile, as the command can
fail for other reasons, e.g. because the system is out of memory.
Directly check if the reflog is empty instead, which is more robust.
Reported-by: Marek Mrva <mrva@eof-studios.com>
Signed-off-by: René Scharfe <l.s.r@web.de>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'builtin/config.c')
0 files changed, 0 insertions, 0 deletions