<rdar://problem/7031922>
Created attachment 38948 [details] The patch
Comment on attachment 38948 [details] The patch > Index: JavaScriptCore/jit/ExecutableAllocatorPosix.cpp > =================================================================== > --- JavaScriptCore/jit/ExecutableAllocatorPosix.cpp (revision 47901) > +++ JavaScriptCore/jit/ExecutableAllocatorPosix.cpp (working copy) > @@ -44,7 +44,10 @@ void ExecutableAllocator::intializePageS > > ExecutablePool::Allocation ExecutablePool::systemAlloc(size_t n) > { > - ExecutablePool::Allocation alloc = { reinterpret_cast<char*>(mmap(NULL, n, INITIAL_PROTECTION_FLAGS, MAP_PRIVATE | MAP_ANON, VM_TAG_FOR_EXECUTABLEALLOCATOR_MEMORY, 0)), n }; > + void* allocation = mmap(NULL, n, INITIAL_PROTECTION_FLAGS, MAP_PRIVATE | MAP_ANON, VM_TAG_FOR_EXECUTABLEALLOCATOR_MEMORY, 0); > + if (allocation == (void*)-1) Can we use the MAP_FAILED constant here? Otherwise, r=me
Sending JavaScriptCore/ChangeLog Sending JavaScriptCore/jit/ExecutableAllocatorPosix.cpp Sending JavaScriptCore/jit/ExecutableAllocatorWin.cpp Transmitting file data ... Committed revision 48000.