Skip to content

Commit 3f837c3

Browse files
committed
backport 4a85f6ae9f0381f0e29160fb1d304d7bde5840ba
1 parent 74acd38 commit 3f837c3

File tree

4 files changed

+16
-15
lines changed

4 files changed

+16
-15
lines changed

make/autoconf/flags-cflags.m4

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -625,7 +625,7 @@ AC_DEFUN([FLAGS_SETUP_CFLAGS_HELPER],
625625
TOOLCHAIN_CFLAGS_JVM="-qtbtable=full -qtune=balanced -fno-exceptions \
626626
-qalias=noansi -qstrict -qtls=default -qnortti -qnoeh -qignerrno -qstackprotect"
627627
elif test "x$TOOLCHAIN_TYPE" = xmicrosoft; then
628-
TOOLCHAIN_CFLAGS_JVM="-nologo -MD -Zc:preprocessor -Zc:strictStrings -MP"
628+
TOOLCHAIN_CFLAGS_JVM="-nologo -MD -Zc:preprocessor -Zc:strictStrings -permissive- -MP"
629629
TOOLCHAIN_CFLAGS_JDK="-nologo -MD -Zc:preprocessor -Zc:strictStrings -Zc:wchar_t-"
630630
fi
631631

src/hotspot/os/windows/os_windows.cpp

Lines changed: 12 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -2284,7 +2284,7 @@ void* os::win32::install_signal_handler(int sig, signal_handler_t handler) {
22842284
sigbreakHandler = handler;
22852285
return oldHandler;
22862286
} else {
2287-
return ::signal(sig, handler);
2287+
return CAST_FROM_FN_PTR(void*, ::signal(sig, handler));
22882288
}
22892289
}
22902290

@@ -2935,22 +2935,23 @@ LONG WINAPI topLevelVectoredExceptionFilter(struct _EXCEPTION_POINTERS* exceptio
29352935

29362936
#if defined(USE_VECTORED_EXCEPTION_HANDLING)
29372937
LONG WINAPI topLevelUnhandledExceptionFilter(struct _EXCEPTION_POINTERS* exceptionInfo) {
2938-
if (InterceptOSException) goto exit;
2939-
DWORD exception_code = exceptionInfo->ExceptionRecord->ExceptionCode;
2938+
if (!InterceptOSException) {
2939+
DWORD exceptionCode = exceptionInfo->ExceptionRecord->ExceptionCode;
29402940
#if defined(_M_ARM64)
2941-
address pc = (address)exceptionInfo->ContextRecord->Pc;
2941+
address pc = (address) exceptionInfo->ContextRecord->Pc;
29422942
#elif defined(_M_AMD64)
2943-
address pc = (address) exceptionInfo->ContextRecord->Rip;
2943+
address pc = (address) exceptionInfo->ContextRecord->Rip;
29442944
#else
2945-
address pc = (address) exceptionInfo->ContextRecord->Eip;
2945+
address pc = (address) exceptionInfo->ContextRecord->Eip;
29462946
#endif
2947-
Thread* t = Thread::current_or_null_safe();
2947+
Thread* thread = Thread::current_or_null_safe();
29482948

2949-
if (exception_code != EXCEPTION_BREAKPOINT) {
2950-
report_error(t, exception_code, pc, exceptionInfo->ExceptionRecord,
2951-
exceptionInfo->ContextRecord);
2949+
if (exceptionCode != EXCEPTION_BREAKPOINT) {
2950+
report_error(thread, exceptionCode, pc, exceptionInfo->ExceptionRecord,
2951+
exceptionInfo->ContextRecord);
2952+
}
29522953
}
2953-
exit:
2954+
29542955
return previousUnhandledExceptionFilter ? previousUnhandledExceptionFilter(exceptionInfo) : EXCEPTION_CONTINUE_SEARCH;
29552956
}
29562957
#endif

src/hotspot/os/windows/symbolengine.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -111,7 +111,7 @@ class SimpleBufferWithFallback {
111111
_p = _fallback_buffer;
112112
_capacity = (int)(sizeof(_fallback_buffer) / sizeof(T));
113113
}
114-
_p[0] = '\0';
114+
_p[0] = 0;
115115
imprint_sentinel();
116116
}
117117

@@ -123,7 +123,7 @@ class SimpleBufferWithFallback {
123123
}
124124
_p = _fallback_buffer;
125125
_capacity = (int)(sizeof(_fallback_buffer) / sizeof(T));
126-
_p[0] = '\0';
126+
_p[0] = 0;
127127
imprint_sentinel();
128128
}
129129

src/hotspot/share/memory/allocation.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -111,7 +111,7 @@ void* ArenaObj::operator new(size_t size, Arena *arena) throw() {
111111
// AnyObj
112112
//
113113

114-
void* AnyObj::operator new(size_t size, Arena *arena) throw() {
114+
void* AnyObj::operator new(size_t size, Arena *arena) {
115115
address res = (address)arena->Amalloc(size);
116116
DEBUG_ONLY(set_allocation_type(res, ARENA);)
117117
return res;

0 commit comments

Comments
 (0)