builtin-apply.c: do not set bogus mode in check_preimage() for deleted path

If it is deleted, it is deleted.  Do not set the current mode to it.

Signed-off-by: Junio C Hamano <gitster@pobox.com>
diff --git a/builtin-apply.c b/builtin-apply.c
index a8f75ed..8248e09 100644
--- a/builtin-apply.c
+++ b/builtin-apply.c
@@ -2447,7 +2447,7 @@
 	if (st_mode != patch->old_mode)
 		fprintf(stderr, "warning: %s has type %o, expected %o\n",
 			old_name, st_mode, patch->old_mode);
-	if (!patch->new_mode)
+	if (!patch->new_mode && !patch->is_delete)
 		patch->new_mode = st_mode;
 	return 0;