diff options
| author | dgp <dgp@users.sourceforge.net> | 2018-06-12 18:02:24 (GMT) |
|---|---|---|
| committer | dgp <dgp@users.sourceforge.net> | 2018-06-12 18:02:24 (GMT) |
| commit | a54459bed607a9d65134f2d5b535e29f75c0d252 (patch) | |
| tree | 35ebae2d63bc07792e3d361d8ac718fe69a22492 /unix/tclUnixNotfy.c | |
| parent | 7fe9e1b90c4464f3f288cecc3fa1d65bb6904cd1 (diff) | |
| parent | f2ec60553a7e3f8cc433362a672fa9eea014b332 (diff) | |
| download | tcl-a54459bed607a9d65134f2d5b535e29f75c0d252.zip tcl-a54459bed607a9d65134f2d5b535e29f75c0d252.tar.gz tcl-a54459bed607a9d65134f2d5b535e29f75c0d252.tar.bz2 | |
close fork
Diffstat (limited to 'unix/tclUnixNotfy.c')
| -rw-r--r-- | unix/tclUnixNotfy.c | 26 |
1 files changed, 13 insertions, 13 deletions
diff --git a/unix/tclUnixNotfy.c b/unix/tclUnixNotfy.c index b7df740..fb7e569 100644 --- a/unix/tclUnixNotfy.c +++ b/unix/tclUnixNotfy.c @@ -12,29 +12,30 @@ */ #include <poll.h> +#include "tclInt.h" /* * Static routines defined in this file. */ -#ifdef NOTIFIER_SELECT -#ifdef TCL_THREADS +static int FileHandlerEventProc(Tcl_Event *evPtr, int flags); +#if !TCL_THREADS +# undef NOTIFIER_EPOLL +# undef NOTIFIER_KQUEUE +# define NOTIFIER_SELECT +#elif !defined(NOTIFIER_EPOLL) && !defined(NOTIFIER_KQUEUE) +# define NOTIFIER_SELECT static TCL_NORETURN void NotifierThreadProc(ClientData clientData); -#if defined(HAVE_PTHREAD_ATFORK) +# if defined(HAVE_PTHREAD_ATFORK) static void AtForkChild(void); -#endif /* HAVE_PTHREAD_ATFORK */ -#endif /* TCL_THREADS */ -#endif /* NOTIFIER_SELECT */ -static int FileHandlerEventProc(Tcl_Event *evPtr, int flags); +# endif /* HAVE_PTHREAD_ATFORK */ -#ifdef NOTIFIER_SELECT -#if TCL_THREADS /* *---------------------------------------------------------------------- * * StartNotifierThread -- * - * Start a notfier thread and wait for the notifier pipe to be created. + * Start a notifier thread and wait for the notifier pipe to be created. * * Results: * None. @@ -70,7 +71,6 @@ StartNotifierThread(const char *proc) pthread_mutex_unlock(¬ifierInitMutex); } } -#endif /* TCL_THREADS */ #endif /* NOTIFIER_SELECT */ /* @@ -107,7 +107,7 @@ Tcl_AlertNotifier( return; } else { #ifdef NOTIFIER_SELECT -#ifdef TCL_THREADS +#if TCL_THREADS ThreadSpecificData *tsdPtr = clientData; pthread_mutex_lock(¬ifierMutex); @@ -280,7 +280,7 @@ FileHandlerEventProc( } #ifdef NOTIFIER_SELECT -#ifdef TCL_THREADS +#if TCL_THREADS /* *---------------------------------------------------------------------- * |
