summaryrefslogtreecommitdiff
path: root/src/pal
diff options
context:
space:
mode:
Diffstat (limited to 'src/pal')
-rw-r--r--src/pal/inc/pal.h1
-rw-r--r--src/pal/src/exception/seh.cpp8
-rw-r--r--src/pal/src/misc/time.cpp10
-rw-r--r--src/pal/src/thread/context.cpp1
-rw-r--r--src/pal/tests/palsuite/eventprovider/CMakeLists.txt3
5 files changed, 11 insertions, 12 deletions
diff --git a/src/pal/inc/pal.h b/src/pal/inc/pal.h
index cec19c290e..c139efcba8 100644
--- a/src/pal/inc/pal.h
+++ b/src/pal/inc/pal.h
@@ -3547,6 +3547,7 @@ SetErrorMode(
#define MEM_RESERVE 0x2000
#define MEM_DECOMMIT 0x4000
#define MEM_RELEASE 0x8000
+#define MEM_RESET 0x80000
#define MEM_FREE 0x10000
#define MEM_PRIVATE 0x20000
#define MEM_MAPPED 0x40000
diff --git a/src/pal/src/exception/seh.cpp b/src/pal/src/exception/seh.cpp
index 87bc677296..7acb3dce1e 100644
--- a/src/pal/src/exception/seh.cpp
+++ b/src/pal/src/exception/seh.cpp
@@ -77,20 +77,16 @@ Return value :
BOOL
SEHInitialize (CPalThread *pthrCurrent, DWORD flags)
{
- BOOL bRet = FALSE;
-
#if !HAVE_MACH_EXCEPTIONS
if (!SEHInitializeSignals())
{
ERROR("SEHInitializeSignals failed!\n");
SEHCleanup();
- goto SEHInitializeExit;
+ return FALSE;
}
#endif
- bRet = TRUE;
-SEHInitializeExit:
- return bRet;
+ return TRUE;
}
/*++
diff --git a/src/pal/src/misc/time.cpp b/src/pal/src/misc/time.cpp
index 939c86996a..17fe037372 100644
--- a/src/pal/src/misc/time.cpp
+++ b/src/pal/src/misc/time.cpp
@@ -202,6 +202,7 @@ QueryPerformanceCounter(
PERF_ENTRY(QueryPerformanceCounter);
ENTRY("QueryPerformanceCounter()\n");
+ do
#if HAVE_CLOCK_MONOTONIC
{
struct timespec ts;
@@ -209,7 +210,7 @@ QueryPerformanceCounter(
{
ASSERT("clock_gettime(CLOCK_MONOTONIC) failed; errno is %d (%s)\n", errno, strerror(errno));
retval = FALSE;
- goto EXIT;
+ break;
}
lpPerformanceCount->QuadPart =
(LONGLONG)ts.tv_sec * (LONGLONG)tccSecondsToNanoSeconds + (LONGLONG)ts.tv_nsec;
@@ -230,7 +231,7 @@ QueryPerformanceCounter(
{
ASSERT("time_base_to_time() failed; errno is %d (%s)\n", errno, strerror(errno));
retval = FALSE;
- goto EXIT;
+ break;
}
lpPerformanceCount->QuadPart =
(LONGLONG)tb.tb_high * (LONGLONG)tccSecondsToNanoSeconds + (LONGLONG)tb.tb_low;
@@ -242,13 +243,14 @@ QueryPerformanceCounter(
{
ASSERT("gettimeofday() failed; errno is %d (%s)\n", errno, strerror(errno));
retval = FALSE;
- goto EXIT;
+ break;
}
lpPerformanceCount->QuadPart =
(LONGLONG)tv.tv_sec * (LONGLONG)tccSecondsToMicroSeconds + (LONGLONG)tv.tv_usec;
}
#endif // HAVE_CLOCK_MONOTONIC
-EXIT:
+ while (false);
+
LOGEXIT("QueryPerformanceCounter\n");
PERF_EXIT(QueryPerformanceCounter);
return retval;
diff --git a/src/pal/src/thread/context.cpp b/src/pal/src/thread/context.cpp
index ebd4383a71..dfb1c4baf1 100644
--- a/src/pal/src/thread/context.cpp
+++ b/src/pal/src/thread/context.cpp
@@ -220,7 +220,6 @@ BOOL CONTEXT_GetRegisters(DWORD processId, LPCONTEXT lpContext)
bRet = TRUE;
#if HAVE_BSD_REGS_T
-EXIT :
if (regFd != -1)
{
close(regFd);
diff --git a/src/pal/tests/palsuite/eventprovider/CMakeLists.txt b/src/pal/tests/palsuite/eventprovider/CMakeLists.txt
index 32b59592ee..41289f92f2 100644
--- a/src/pal/tests/palsuite/eventprovider/CMakeLists.txt
+++ b/src/pal/tests/palsuite/eventprovider/CMakeLists.txt
@@ -10,7 +10,6 @@ set(SOURCES
include_directories(${COREPAL_SOURCE_DIR}/prebuilt/inc)
include_directories(${COREPAL_SOURCE_DIR}/inc/rt)
-
add_executable(eventprovidertest
${SOURCES}
)
@@ -18,6 +17,8 @@ set(EVENT_PROVIDER_DEPENDENCIES "")
set(EVENT_PROVIDER_LINKER_OTPTIONS "")
if(CMAKE_SYSTEM_NAME STREQUAL Linux)
+ add_definitions(-DFEATURE_EVENT_TRACE=1)
+
list(APPEND EVENT_PROVIDER_DEPENDENCIES
eventprovider
)