Mercurial > hg > graal-jvmci-8
comparison src/os/solaris/vm/os_solaris.cpp @ 23020:bbceafdc7a5f
6536943: Bogus -Xcheck:jni warning for SIG_INT action for SIGINT in JVM started from non-interactive shell
Summary: check_signal_handler will print out Warning for SHURDOWN2_SIGNAL (SIGINT) is replaced by non-interactive shell. Fix by supply more information of the replacement to user.
Reviewed-by: dholmes
Contributed-by: yumin.qi@oracle.com
author | minqi |
---|---|
date | Thu, 14 May 2015 20:56:57 -0700 |
parents | 41a855ff6305 |
children | dd9cc155639c 3ad3f93fe3d2 |
comparison
equal
deleted
inserted
replaced
23011:1e96e4389302 | 23020:bbceafdc7a5f |
---|---|
1 /* | 1 /* |
2 * Copyright (c) 1997, 2014, Oracle and/or its affiliates. All rights reserved. | 2 * Copyright (c) 1997, 2015, Oracle and/or its affiliates. All rights reserved. |
3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. | 3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. |
4 * | 4 * |
5 * This code is free software; you can redistribute it and/or modify it | 5 * This code is free software; you can redistribute it and/or modify it |
6 * under the terms of the GNU General Public License version 2 only, as | 6 * under the terms of the GNU General Public License version 2 only, as |
7 * published by the Free Software Foundation. | 7 * published by the Free Software Foundation. |
4591 tty->print("Warning: %s handler ", exception_name(sig, buf, O_BUFLEN)); | 4591 tty->print("Warning: %s handler ", exception_name(sig, buf, O_BUFLEN)); |
4592 tty->print("expected:%s", get_signal_handler_name(jvmHandler, buf, O_BUFLEN)); | 4592 tty->print("expected:%s", get_signal_handler_name(jvmHandler, buf, O_BUFLEN)); |
4593 tty->print_cr(" found:%s", get_signal_handler_name(thisHandler, buf, O_BUFLEN)); | 4593 tty->print_cr(" found:%s", get_signal_handler_name(thisHandler, buf, O_BUFLEN)); |
4594 // No need to check this sig any longer | 4594 // No need to check this sig any longer |
4595 sigaddset(&check_signal_done, sig); | 4595 sigaddset(&check_signal_done, sig); |
4596 // Running under non-interactive shell, SHUTDOWN2_SIGNAL will be reassigned SIG_IGN | |
4597 if (sig == SHUTDOWN2_SIGNAL && !isatty(fileno(stdin))) { | |
4598 tty->print_cr("Running in non-interactive shell, %s handler is replaced by shell", | |
4599 exception_name(sig, buf, O_BUFLEN)); | |
4600 } | |
4596 } else if(os::Solaris::get_our_sigflags(sig) != 0 && act.sa_flags != os::Solaris::get_our_sigflags(sig)) { | 4601 } else if(os::Solaris::get_our_sigflags(sig) != 0 && act.sa_flags != os::Solaris::get_our_sigflags(sig)) { |
4597 tty->print("Warning: %s handler flags ", exception_name(sig, buf, O_BUFLEN)); | 4602 tty->print("Warning: %s handler flags ", exception_name(sig, buf, O_BUFLEN)); |
4598 tty->print("expected:" PTR32_FORMAT, os::Solaris::get_our_sigflags(sig)); | 4603 tty->print("expected:" PTR32_FORMAT, os::Solaris::get_our_sigflags(sig)); |
4599 tty->print_cr(" found:" PTR32_FORMAT, act.sa_flags); | 4604 tty->print_cr(" found:" PTR32_FORMAT, act.sa_flags); |
4600 // No need to check this sig any longer | 4605 // No need to check this sig any longer |