~ubuntu-branches/ubuntu/maverick/openssl/maverick

« back to all changes in this revision

Viewing changes to crypto/mem_dbg.c

  • Committer: Bazaar Package Importer
  • Author(s): Kurt Roeckx
  • Date: 2005-12-13 21:37:42 UTC
  • mto: (11.1.1 lenny)
  • mto: This revision was merged to the branch mainline in revision 4.
  • Revision ID: james.westby@ubuntu.com-20051213213742-d0ydaylf80l16bj1
Tags: upstream-0.9.8a
ImportĀ upstreamĀ versionĀ 0.9.8a

Show diffs side-by-side

added added

removed removed

Lines of Context:
59
59
#include <stdio.h>
60
60
#include <stdlib.h>
61
61
#include <time.h>       
 
62
#include "cryptlib.h"
62
63
#include <openssl/crypto.h>
63
64
#include <openssl/buffer.h>
64
65
#include <openssl/bio.h>
65
66
#include <openssl/lhash.h>
66
 
#include "cryptlib.h"
67
67
 
68
68
static int mh_mode=CRYPTO_MEM_CHECK_OFF;
69
69
/* The state changes to CRYPTO_MEM_CHECK_ON | CRYPTO_MEM_CHECK_ENABLE
252
252
/* static int mem_cmp(MEM *a, MEM *b) */
253
253
static int mem_cmp(const void *a_void, const void *b_void)
254
254
        {
 
255
#ifdef _WIN64
 
256
        const char *a=(const char *)((const MEM *)a_void)->addr,
 
257
                   *b=(const char *)((const MEM *)b_void)->addr;
 
258
        if (a==b)       return 0;
 
259
        else if (a>b)   return 1;
 
260
        else            return -1;
 
261
#else
255
262
        return((const char *)((const MEM *)a_void)->addr
256
263
                - (const char *)((const MEM *)b_void)->addr);
 
264
#endif
257
265
        }
258
266
 
259
267
/* static unsigned long mem_hash(MEM *a) */