Ignore:
Timestamp:
Sep 15, 2009, 6:03:32 AM (16 years ago)
Author:
[email protected]
Message:

[Qt] Build fix for windows.

Patch by Csaba Osztrogonac <[email protected]> on 2009-09-15
Reviewed by Tor Arne Vestbø.

After http://trac.webkit.org/changeset/47795 the MinGW build broke,
because MinGW has mingw_aligned_malloc instead of _aligned_malloc.

  • runtime/Collector.cpp:

(JSC::Heap::allocateBlock): MinGW case added.
(JSC::Heap::freeBlock): MinGW case added.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/JavaScriptCore/runtime/Collector.cpp

    r48315 r48391  
    238238    memset(reinterpret_cast<void*>(address), 0, BLOCK_SIZE);
    239239#elif PLATFORM(WIN_OS)
     240#if COMPILER(MINGW)
     241    void* address = __mingw_aligned_malloc(BLOCK_SIZE, BLOCK_SIZE);
     242#else
    240243    void* address = _aligned_malloc(BLOCK_SIZE, BLOCK_SIZE);
     244#endif
    241245    memset(address, 0, BLOCK_SIZE);
    242246#elif HAVE(POSIX_MEMALIGN)
     
    316320    userChunk->Free(reinterpret_cast<TAny*>(block));
    317321#elif PLATFORM(WIN_OS)
     322#if COMPILER(MINGW)
     323    __mingw_aligned_free(block);
     324#else
    318325    _aligned_free(block);
     326#endif
    319327#elif HAVE(POSIX_MEMALIGN)
    320328    free(block);
Note: See TracChangeset for help on using the changeset viewer.