From 9742f673fdedb7146a6a6e7dc842147e8b5e3069 Mon Sep 17 00:00:00 2001 From: Andrew Bartlett Date: Mon, 13 Jan 2003 08:09:32 +0000 Subject: Ensure we do not pass uninitialised data to the kernel. (Picked up by valgrind). Andrew Bartlett (This used to be commit f8d9880c5f5321f4dba6b42896419412284c3e7b) --- source3/smbd/notify_kernel.c | 2 ++ source3/smbd/oplock_linux.c | 2 ++ 2 files changed, 4 insertions(+) diff --git a/source3/smbd/notify_kernel.c b/source3/smbd/notify_kernel.c index df553721ef..8b7ff21ecb 100644 --- a/source3/smbd/notify_kernel.c +++ b/source3/smbd/notify_kernel.c @@ -215,6 +215,8 @@ struct cnotify_fns *kernel_notify_init(void) static struct cnotify_fns cnotify; struct sigaction act; + ZERO_STRUCT(act); + act.sa_handler = NULL; act.sa_sigaction = signal_handler; act.sa_flags = SA_SIGINFO; diff --git a/source3/smbd/oplock_linux.c b/source3/smbd/oplock_linux.c index 85f89c12a0..deed0c5107 100644 --- a/source3/smbd/oplock_linux.c +++ b/source3/smbd/oplock_linux.c @@ -279,6 +279,8 @@ struct kernel_oplocks *linux_init_kernel_oplocks(void) return NULL; } + ZERO_STRUCT(act); + act.sa_handler = NULL; act.sa_sigaction = signal_handler; act.sa_flags = SA_SIGINFO; -- cgit