8182034: os::Posix::is_valid_signal() should, if it uses sigaddset, initialize the signal set
authorstuefe
Tue, 13 Jun 2017 08:09:17 +0200
changeset 46558 13de3946d61e
parent 46556 beb2c322626d
child 46559 18f2673beac8
8182034: os::Posix::is_valid_signal() should, if it uses sigaddset, initialize the signal set Summary: Added missing sigemptyset. Reviewed-by: kbarrett, clanger
hotspot/src/os/posix/vm/os_posix.cpp
--- a/hotspot/src/os/posix/vm/os_posix.cpp	Thu Jun 22 13:59:00 2017 -0700
+++ b/hotspot/src/os/posix/vm/os_posix.cpp	Tue Jun 13 08:09:17 2017 +0200
@@ -760,6 +760,7 @@
 #else
   // Use sigaddset to check for signal validity.
   sigset_t set;
+  sigemptyset(&set);
   if (sigaddset(&set, sig) == -1 && errno == EINVAL) {
     return false;
   }