From 7c972a103a636e5dfe4341748ac8d8401a2d2e5d Mon Sep 17 00:00:00 2001 From: Thomas Stuefe Date: Tue, 13 Jun 2017 08:09:17 +0200 Subject: [PATCH] 8182034: os::Posix::is_valid_signal() should, if it uses sigaddset, initialize the signal set Added missing sigemptyset. Reviewed-by: kbarrett, clanger --- hotspot/src/os/posix/vm/os_posix.cpp | 1 + 1 file changed, 1 insertion(+) diff --git a/hotspot/src/os/posix/vm/os_posix.cpp b/hotspot/src/os/posix/vm/os_posix.cpp index 2a165c1e581..551f522f6a2 100644 --- a/hotspot/src/os/posix/vm/os_posix.cpp +++ b/hotspot/src/os/posix/vm/os_posix.cpp @@ -760,6 +760,7 @@ bool os::Posix::is_valid_signal(int sig) { #else // Use sigaddset to check for signal validity. sigset_t set; + sigemptyset(&set); if (sigaddset(&set, sig) == -1 && errno == EINVAL) { return false; }