equal
deleted
inserted
replaced
1 /* |
1 /* |
2 * Copyright (c) 2002, 2006, Oracle and/or its affiliates. All rights reserved. |
2 * Copyright (c) 2002, 2016, 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. Oracle designates this |
7 * published by the Free Software Foundation. Oracle designates this |
91 #ifdef __solaris__ |
91 #ifdef __solaris__ |
92 ret = thr_kill((thread_t)thread, INTERRUPT_SIGNAL); |
92 ret = thr_kill((thread_t)thread, INTERRUPT_SIGNAL); |
93 #else |
93 #else |
94 ret = pthread_kill((pthread_t)thread, INTERRUPT_SIGNAL); |
94 ret = pthread_kill((pthread_t)thread, INTERRUPT_SIGNAL); |
95 #endif |
95 #endif |
|
96 #ifdef MACOSX |
|
97 if (ret != 0 && ret != ESRCH) |
|
98 #else |
96 if (ret != 0) |
99 if (ret != 0) |
|
100 #endif |
97 JNU_ThrowIOExceptionWithLastError(env, "Thread signal failed"); |
101 JNU_ThrowIOExceptionWithLastError(env, "Thread signal failed"); |
98 } |
102 } |