Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.kernel.org/pub/scm/git/git.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJunio C Hamano <gitster@pobox.com>2009-02-01 04:43:56 +0300
committerJunio C Hamano <gitster@pobox.com>2009-02-01 04:43:56 +0300
commitfa5bc8abb35e34f673c41cb5c66d0a2f21536861 (patch)
treee76e7f9d8d64db34f148f7ddfa6bca928c194d65 /builtin-clone.c
parent2edefe38a813deb4dfbd62dcf47520aeb1af15fc (diff)
parent0ea8039644968e53d79a8dfbf739c87af4261d46 (diff)
Merge branch 'jk/signal-cleanup'
* jk/signal-cleanup: t0005: use SIGTERM for sigchain test pager: do wait_for_pager on signal death refactor signal handling for cleanup functions chain kill signals for cleanup functions diff: refactor tempfile cleanup handling Windows: Fix signal numbers
Diffstat (limited to 'builtin-clone.c')
-rw-r--r--builtin-clone.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/builtin-clone.c b/builtin-clone.c
index 1e9c9aa844..f73029e2ba 100644
--- a/builtin-clone.c
+++ b/builtin-clone.c
@@ -19,6 +19,7 @@
#include "strbuf.h"
#include "dir.h"
#include "pack-refs.h"
+#include "sigchain.h"
/*
* Overall FIXMEs:
@@ -288,7 +289,7 @@ static void remove_junk(void)
static void remove_junk_on_signal(int signo)
{
remove_junk();
- signal(SIGINT, SIG_DFL);
+ sigchain_pop(signo);
raise(signo);
}
@@ -441,7 +442,7 @@ int cmd_clone(int argc, const char **argv, const char *prefix)
}
junk_git_dir = git_dir;
atexit(remove_junk);
- signal(SIGINT, remove_junk_on_signal);
+ sigchain_push_common(remove_junk_on_signal);
setenv(CONFIG_ENVIRONMENT, xstrdup(mkpath("%s/config", git_dir)), 1);