gfx/cairo/win32-inline-cpp-keyword.patch

Tue, 06 Jan 2015 21:39:09 +0100

author
Michael Schloh von Bennewitz <michael@schloh.com>
date
Tue, 06 Jan 2015 21:39:09 +0100
branch
TOR_BUG_9701
changeset 8
97036ab72558
permissions
-rw-r--r--

Conditionally force memory storage according to privacy.thirdparty.isolate;
This solves Tor bug #9701, complying with disk avoidance documented in
https://www.torproject.org/projects/torbrowser/design/#disk-avoidance.

     1 diff --git a/gfx/cairo/cairo/src/cairo-compiler-private.h b/gfx/cairo/cairo/src/cairo-compiler-private.h
     2 --- a/gfx/cairo/cairo/src/cairo-compiler-private.h
     3 +++ b/gfx/cairo/cairo/src/cairo-compiler-private.h
     4 @@ -205,18 +205,20 @@
     5  #if (defined(__WIN32__) && !defined(__WINE__)) || defined(_MSC_VER)
     6  #define snprintf _snprintf
     7  #define popen _popen
     8  #define pclose _pclose
     9  #define hypot _hypot
    10  #endif
    12  #ifdef _MSC_VER
    13 +#ifndef __cplusplus
    14  #undef inline
    15  #define inline __inline
    16 +#endif
    18  /* there are currently linkage problems that arise when trying to include intrin.h in c++:
    19   * D:\sdks\v7.0\include\winnt.h(3674) : error C2733: second C linkage of overloaded function '_interlockedbittestandset' not allowed
    20   * so avoid defining ffs in c++ code for now */
    21  #ifndef  __cplusplus
    22  /* Add a definition of ffs */
    23  #include <intrin.h>
    24  #pragma intrinsic(_BitScanForward)

mercurial