summaryrefslogtreecommitdiffstats
path: root/unix/tclXtNotify.c
diff options
context:
space:
mode:
authorjan.nijtmans <nijtmans@users.sourceforge.net>2022-04-26 07:29:02 (GMT)
committerjan.nijtmans <nijtmans@users.sourceforge.net>2022-04-26 07:29:02 (GMT)
commita4c35fb82f99d990ca1ef877cb9917c7f55151ff (patch)
treecdd02327448cf2c0393cbf3cea4fd48bb17e52c4 /unix/tclXtNotify.c
parent81a213ed4ce77b15fbc6d5d97cc1235b689ad482 (diff)
parente12b1646c6f675cf09d5f1a72d4ecdffa5da7396 (diff)
downloadtcl-a4c35fb82f99d990ca1ef877cb9917c7f55151ff.zip
tcl-a4c35fb82f99d990ca1ef877cb9917c7f55151ff.tar.gz
tcl-a4c35fb82f99d990ca1ef877cb9917c7f55151ff.tar.bz2
Merge 8.7
Diffstat (limited to 'unix/tclXtNotify.c')
-rw-r--r--unix/tclXtNotify.c17
1 files changed, 7 insertions, 10 deletions
diff --git a/unix/tclXtNotify.c b/unix/tclXtNotify.c
index 3d90135..45bda3e 100644
--- a/unix/tclXtNotify.c
+++ b/unix/tclXtNotify.c
@@ -181,7 +181,13 @@ TclSetAppContext(
void
InitNotifier(void)
{
- Tcl_NotifierProcs np;
+ static const Tcl_NotifierProcs np =
+ SetTimer,
+ WaitForEvent,
+ CreateFileHandler,
+ DeleteFileHandler,
+ NULL, NULL, NULL, NULL
+ };
/*
* Only reinitialize if we are not in exit handling. The notifier can get
@@ -193,14 +199,6 @@ InitNotifier(void)
return;
}
- np.createFileHandlerProc = CreateFileHandler;
- np.deleteFileHandlerProc = DeleteFileHandler;
- np.setTimerProc = SetTimer;
- np.waitForEventProc = WaitForEvent;
- np.initNotifierProc = Tcl_InitNotifier;
- np.finalizeNotifierProc = Tcl_FinalizeNotifier;
- np.alertNotifierProc = Tcl_AlertNotifier;
- np.serviceModeHookProc = Tcl_ServiceModeHook;
Tcl_SetNotifier(&np);
/*
@@ -209,7 +207,6 @@ InitNotifier(void)
*/
initialized = 1;
- memset(&np, 0, sizeof(np));
Tcl_CreateExitHandler(NotifierExitHandler, NULL);
}