fixed GH #618: OS X 10.10 defines PAGE_SIZE macro, conflicts with PAGE_SIZE in Thread_POSIX.cpp

This commit is contained in:
Guenter Obiltschnig 2014-11-21 14:47:33 +01:00
parent f09ed71a47
commit 77bbc7e9ba

View File

@ -167,8 +167,8 @@ void ThreadImpl::setStackSizeImpl(int size)
{
#if defined(POCO_OS_FAMILY_BSD)
// we must round up to a multiple of the memory page size
const int PAGE_SIZE = 4096;
size = ((size + PAGE_SIZE - 1)/PAGE_SIZE)*PAGE_SIZE;
const int STACK_PAGE_SIZE = 4096;
size = ((size + STACK_PAGE_SIZE - 1)/STACK_PAGE_SIZE)*STACK_PAGE_SIZE;
#endif
#if !defined(POCO_ANDROID)
if (size < PTHREAD_STACK_MIN)