X-Git-Url: https://git.librecmc.org/?a=blobdiff_plain;f=crypto%2Fmem_dbg.c;h=8316485217ac48847f59ce5ce8a51ba86df2ff97;hb=2c16e78400e97f0294feda8a55a81c73b15f7e78;hp=e212de27e488df64c0a7879a40b3792b61f418e6;hpb=d420ac2c7d4ba9d99ff2c257a3ad71ecc6d876e2;p=oweals%2Fopenssl.git diff --git a/crypto/mem_dbg.c b/crypto/mem_dbg.c index e212de27e4..8316485217 100644 --- a/crypto/mem_dbg.c +++ b/crypto/mem_dbg.c @@ -59,11 +59,11 @@ #include #include #include +#include "cryptlib.h" #include #include #include #include -#include "cryptlib.h" static int mh_mode=CRYPTO_MEM_CHECK_OFF; /* The state changes to CRYPTO_MEM_CHECK_ON | CRYPTO_MEM_CHECK_ENABLE @@ -252,8 +252,16 @@ long CRYPTO_dbg_get_options(void) /* static int mem_cmp(MEM *a, MEM *b) */ static int mem_cmp(const void *a_void, const void *b_void) { +#ifdef _WIN64 + const char *a=(const char *)((const MEM *)a_void)->addr, + *b=(const char *)((const MEM *)b_void)->addr; + if (a==b) return 0; + else if (a>b) return 1; + else return -1; +#else return((const char *)((const MEM *)a_void)->addr - (const char *)((const MEM *)b_void)->addr); +#endif } /* static unsigned long mem_hash(MEM *a) */