Mercurial > gftp.yaz
diff src/gtk/mkdir_dialog.c @ 42:cd169e4789df
2002-10-29 Brian Masney <masneyb@gftp.org>
* src/gtk/chmod_dialog.c src/gtk/delete_dialog.c src/gtk/gftp-gtk.c
src/gtk/gftp-gtk.h src/gtk/menu-items.c src/gtk/misc-gtk.c
src/gtk/mkdir_dialog.c src/gtk/rename_dialog.c src/gtk/transfer.c -
improved and simplified signal handling code
author | masneyb |
---|---|
date | Wed, 30 Oct 2002 03:34:37 +0000 |
parents | c8ec7877432e |
children | eec25f215772 |
line wrap: on
line diff
--- a/src/gtk/mkdir_dialog.c Wed Oct 30 02:53:21 2002 +0000 +++ b/src/gtk/mkdir_dialog.c Wed Oct 30 03:34:37 2002 +0000 @@ -21,15 +21,6 @@ static const char cvsid[] = "$Id$"; static const char *edttext; -static sigjmp_buf mkdirenvir; - - -static RETSIGTYPE -sig_mkdirquit (int signo) -{ - signal (signo, sig_mkdirquit); - siglongjmp (mkdirenvir, signo == SIGINT ? 1 : 2); -} static void * @@ -43,9 +34,8 @@ if (wdata->request->use_threads) { - sj = sigsetjmp (mkdirenvir, 1); - signal (SIGINT, sig_mkdirquit); - signal (SIGALRM, sig_mkdirquit); + sj = sigsetjmp (jmp_environment, 1); + use_jmp_environment = 1; } else sj = 0; @@ -67,10 +57,7 @@ } if (wdata->request->use_threads) - { - signal (SIGINT, SIG_DFL); - signal (SIGALRM, SIG_IGN); - } + use_jmp_environment = 0; wdata->request->user_data = NULL; wdata->request->stopable = 0;