From: Paul Tan Date: Tue, 4 Aug 2015 13:51:44 +0000 (+0800) Subject: builtin-am: handle stray state directory X-Git-Tag: v2.6.0-rc0~77^2~23 X-Git-Url: https://git.lorimer.id.au/gitweb.git/diff_plain/6d42ac2941cac80b44e318d867bae7979c1af6fe?ds=inline;hp=6d42ac2941cac80b44e318d867bae7979c1af6fe builtin-am: handle stray state directory Should git-am terminate unexpectedly between the point where the state directory is created, but the "next" and "last" files are not written yet, a stray state directory will be left behind. As such, since b141f3c (am: handle stray $dotest directory, 2013-06-15), git-am.sh explicitly recognizes such a stray directory, and allows the user to remove it with am --abort. Re-implement this feature in builtin/am.c. Signed-off-by: Paul Tan Signed-off-by: Junio C Hamano ---