From 16c839206a3ec70addd4012d703e86f0dad9f961 Mon Sep 17 00:00:00 2001 From: Bill Hoffman Date: Tue, 5 Oct 2004 12:42:38 -0400 Subject: BUG: change the name of memory.h --- Source/CTest/Curl/base64.c | 2 +- Source/CTest/Curl/connect.c | 2 +- Source/CTest/Curl/content_encoding.c | 2 +- Source/CTest/Curl/cookie.c | 2 +- Source/CTest/Curl/curl_memory.h | 50 ++++++++++++++++++++++++++++++++++++ Source/CTest/Curl/easy.c | 2 +- Source/CTest/Curl/escape.c | 2 +- Source/CTest/Curl/file.c | 2 +- Source/CTest/Curl/formdata.c | 2 +- Source/CTest/Curl/ftp.c | 2 +- Source/CTest/Curl/getdate.c | 2 +- Source/CTest/Curl/getenv.c | 2 +- Source/CTest/Curl/getinfo.c | 2 +- Source/CTest/Curl/hash.c | 2 +- Source/CTest/Curl/hostares.c | 2 +- Source/CTest/Curl/hostasyn.c | 2 +- Source/CTest/Curl/hostip.c | 2 +- Source/CTest/Curl/hostip4.c | 2 +- Source/CTest/Curl/hostip6.c | 2 +- Source/CTest/Curl/hostsyn.c | 2 +- Source/CTest/Curl/hostthre.c | 2 +- Source/CTest/Curl/http.c | 2 +- Source/CTest/Curl/http_chunks.c | 2 +- Source/CTest/Curl/http_digest.c | 2 +- Source/CTest/Curl/http_negotiate.c | 2 +- Source/CTest/Curl/http_ntlm.c | 2 +- Source/CTest/Curl/if2ip.c | 2 +- Source/CTest/Curl/krb4.c | 2 +- Source/CTest/Curl/ldap.c | 2 +- Source/CTest/Curl/llist.c | 2 +- Source/CTest/Curl/memdebug.c | 2 +- Source/CTest/Curl/memory.h | 50 ------------------------------------ Source/CTest/Curl/mprintf.c | 2 +- Source/CTest/Curl/multi.c | 2 +- Source/CTest/Curl/netrc.c | 2 +- Source/CTest/Curl/nwlib.c | 2 +- Source/CTest/Curl/security.c | 2 +- Source/CTest/Curl/sendf.c | 2 +- Source/CTest/Curl/share.c | 2 +- Source/CTest/Curl/ssluse.c | 2 +- Source/CTest/Curl/telnet.c | 2 +- Source/CTest/Curl/transfer.c | 2 +- Source/CTest/Curl/url.c | 2 +- 43 files changed, 91 insertions(+), 91 deletions(-) create mode 100644 Source/CTest/Curl/curl_memory.h delete mode 100644 Source/CTest/Curl/memory.h diff --git a/Source/CTest/Curl/base64.c b/Source/CTest/Curl/base64.c index 2416bca..6644d2f 100644 --- a/Source/CTest/Curl/base64.c +++ b/Source/CTest/Curl/base64.c @@ -41,7 +41,7 @@ #include #include "base64.h" -#include "memory.h" +#include "curl_memory.h" /* include memdebug.h last */ #include "memdebug.h" diff --git a/Source/CTest/Curl/connect.c b/Source/CTest/Curl/connect.c index d19c5e7..c6bb876 100644 --- a/Source/CTest/Curl/connect.c +++ b/Source/CTest/Curl/connect.c @@ -96,7 +96,7 @@ #include "if2ip.h" #include "strerror.h" #include "connect.h" -#include "memory.h" +#include "curl_memory.h" /* The last #include file should be: */ #include "memdebug.h" diff --git a/Source/CTest/Curl/content_encoding.c b/Source/CTest/Curl/content_encoding.c index b786e3f..b8c68bd 100644 --- a/Source/CTest/Curl/content_encoding.c +++ b/Source/CTest/Curl/content_encoding.c @@ -32,7 +32,7 @@ #include #include "sendf.h" #include "content_encoding.h" -#include "memory.h" +#include "curl_memory.h" #include "memdebug.h" diff --git a/Source/CTest/Curl/cookie.c b/Source/CTest/Curl/cookie.c index 5037314..0f372d8 100644 --- a/Source/CTest/Curl/cookie.c +++ b/Source/CTest/Curl/cookie.c @@ -92,7 +92,7 @@ Example set of cookies: #include "strequal.h" #include "strtok.h" #include "sendf.h" -#include "memory.h" +#include "curl_memory.h" /* The last #include file should be: */ #ifdef CURLDEBUG diff --git a/Source/CTest/Curl/curl_memory.h b/Source/CTest/Curl/curl_memory.h new file mode 100644 index 0000000..4e32a67 --- /dev/null +++ b/Source/CTest/Curl/curl_memory.h @@ -0,0 +1,50 @@ +#ifndef _CURL_MEMORY_H +#define _CURL_MEMORY_H +/*************************************************************************** + * _ _ ____ _ + * Project ___| | | | _ \| | + * / __| | | | |_) | | + * | (__| |_| | _ <| |___ + * \___|\___/|_| \_\_____| + * + * Copyright (C) 1998 - 2004, Daniel Stenberg, , et al. + * + * This software is licensed as described in the file COPYING, which + * you should have received as part of this distribution. The terms + * are also available at http://curl.haxx.se/docs/copyright.html. + * + * You may opt to use, copy, modify, merge, publish, distribute and/or sell + * copies of the Software, and permit persons to whom the Software is + * furnished to do so, under the terms of the COPYING file. + * + * This software is distributed on an "AS IS" basis, WITHOUT WARRANTY OF ANY + * KIND, either express or implied. + * + * $Id$ + ***************************************************************************/ + +#include /* for the typedefs */ + +extern curl_malloc_callback Curl_cmalloc; +extern curl_free_callback Curl_cfree; +extern curl_realloc_callback Curl_crealloc; +extern curl_strdup_callback Curl_cstrdup; +extern curl_calloc_callback Curl_ccalloc; + +#ifndef CURLDEBUG +/* Only do this define-mania if we're not using the memdebug system, as that + has preference on this magic. */ +#undef strdup +#define strdup(ptr) Curl_cstrdup(ptr) +#undef malloc +#define malloc(size) Curl_cmalloc(size) +#undef calloc +#define calloc(nbelem,size) Curl_ccalloc(nbelem, size) +#undef realloc +#define realloc(ptr,size) Curl_crealloc(ptr, size) +#undef free +#define free(ptr) Curl_cfree(ptr) + +#endif + +#endif /* _CURL_MEMORY_H */ diff --git a/Source/CTest/Curl/easy.c b/Source/CTest/Curl/easy.c index 53bd13b..27568f2 100644 --- a/Source/CTest/Curl/easy.c +++ b/Source/CTest/Curl/easy.c @@ -76,7 +76,7 @@ #include "getinfo.h" #include "hostip.h" #include "share.h" -#include "memory.h" +#include "curl_memory.h" #define _MPRINTF_REPLACE /* use our functions only */ #include diff --git a/Source/CTest/Curl/escape.c b/Source/CTest/Curl/escape.c index 4466d4c..d418e5b 100644 --- a/Source/CTest/Curl/escape.c +++ b/Source/CTest/Curl/escape.c @@ -31,7 +31,7 @@ #include #include #include -#include "memory.h" +#include "curl_memory.h" #define _MPRINTF_REPLACE /* use our functions only */ #include diff --git a/Source/CTest/Curl/file.c b/Source/CTest/Curl/file.c index 7cfbf6f..1fe6e5d 100644 --- a/Source/CTest/Curl/file.c +++ b/Source/CTest/Curl/file.c @@ -85,7 +85,7 @@ #include "getinfo.h" #include "transfer.h" #include "url.h" -#include "memory.h" +#include "curl_memory.h" #define _MPRINTF_REPLACE /* use our functions only */ #include diff --git a/Source/CTest/Curl/formdata.c b/Source/CTest/Curl/formdata.c index 4fd83c0..42ed0ec 100644 --- a/Source/CTest/Curl/formdata.c +++ b/Source/CTest/Curl/formdata.c @@ -115,7 +115,7 @@ Content-Disposition: form-data; name="FILECONTENT" #include #include "formdata.h" #include "strequal.h" -#include "memory.h" +#include "curl_memory.h" #define _MPRINTF_REPLACE /* use our functions only */ #include diff --git a/Source/CTest/Curl/ftp.c b/Source/CTest/Curl/ftp.c index 77de831..a6d1587 100644 --- a/Source/CTest/Curl/ftp.c +++ b/Source/CTest/Curl/ftp.c @@ -92,7 +92,7 @@ #include "ssluse.h" #include "connect.h" #include "strerror.h" -#include "memory.h" +#include "curl_memory.h" #include "inet_ntop.h" #if defined(HAVE_INET_NTOA_R) && !defined(HAVE_INET_NTOA_R_DECL) diff --git a/Source/CTest/Curl/getdate.c b/Source/CTest/Curl/getdate.c index cd1df6f..240d0a5 100644 --- a/Source/CTest/Curl/getdate.c +++ b/Source/CTest/Curl/getdate.c @@ -181,7 +181,7 @@ # include #endif -#include "memory.h" +#include "curl_memory.h" /* The last #include file should be: */ #include "memdebug.h" diff --git a/Source/CTest/Curl/getenv.c b/Source/CTest/Curl/getenv.c index a21502c..302db2e 100644 --- a/Source/CTest/Curl/getenv.c +++ b/Source/CTest/Curl/getenv.c @@ -36,7 +36,7 @@ #endif #include -#include "memory.h" +#include "curl_memory.h" #include "memdebug.h" diff --git a/Source/CTest/Curl/getinfo.c b/Source/CTest/Curl/getinfo.c index bdb909e..7316d3a 100644 --- a/Source/CTest/Curl/getinfo.c +++ b/Source/CTest/Curl/getinfo.c @@ -32,7 +32,7 @@ #include #include #include -#include "memory.h" +#include "curl_memory.h" /* Make this the last #include */ #include "memdebug.h" diff --git a/Source/CTest/Curl/hash.c b/Source/CTest/Curl/hash.c index be841b3..614d692 100644 --- a/Source/CTest/Curl/hash.c +++ b/Source/CTest/Curl/hash.c @@ -28,7 +28,7 @@ #include "hash.h" #include "llist.h" -#include "memory.h" +#include "curl_memory.h" /* this must be the last include file */ #include "memdebug.h" diff --git a/Source/CTest/Curl/hostares.c b/Source/CTest/Curl/hostares.c index 48d6211..197f540 100644 --- a/Source/CTest/Curl/hostares.c +++ b/Source/CTest/Curl/hostares.c @@ -87,7 +87,7 @@ #include "inet_ntoa_r.h" #endif -#include "memory.h" +#include "curl_memory.h" /* The last #include file should be: */ #include "memdebug.h" diff --git a/Source/CTest/Curl/hostasyn.c b/Source/CTest/Curl/hostasyn.c index 6256370..b3c9dfa 100644 --- a/Source/CTest/Curl/hostasyn.c +++ b/Source/CTest/Curl/hostasyn.c @@ -87,7 +87,7 @@ #include "inet_ntoa_r.h" #endif -#include "memory.h" +#include "curl_memory.h" /* The last #include file should be: */ #include "memdebug.h" diff --git a/Source/CTest/Curl/hostip.c b/Source/CTest/Curl/hostip.c index 715ec0b..f407435 100644 --- a/Source/CTest/Curl/hostip.c +++ b/Source/CTest/Curl/hostip.c @@ -88,7 +88,7 @@ #include "inet_ntoa_r.h" #endif -#include "memory.h" +#include "curl_memory.h" /* The last #include file should be: */ #include "memdebug.h" diff --git a/Source/CTest/Curl/hostip4.c b/Source/CTest/Curl/hostip4.c index 50d2ada..2a8588e 100644 --- a/Source/CTest/Curl/hostip4.c +++ b/Source/CTest/Curl/hostip4.c @@ -87,7 +87,7 @@ #include "inet_ntoa_r.h" #endif -#include "memory.h" +#include "curl_memory.h" /* The last #include file should be: */ #include "memdebug.h" diff --git a/Source/CTest/Curl/hostip6.c b/Source/CTest/Curl/hostip6.c index 4d7c89f..6717c00 100644 --- a/Source/CTest/Curl/hostip6.c +++ b/Source/CTest/Curl/hostip6.c @@ -87,7 +87,7 @@ #include "inet_ntoa_r.h" #endif -#include "memory.h" +#include "curl_memory.h" /* The last #include file should be: */ #include "memdebug.h" diff --git a/Source/CTest/Curl/hostsyn.c b/Source/CTest/Curl/hostsyn.c index 77ffe71..786f9d9 100644 --- a/Source/CTest/Curl/hostsyn.c +++ b/Source/CTest/Curl/hostsyn.c @@ -87,7 +87,7 @@ #include "inet_ntoa_r.h" #endif -#include "memory.h" +#include "curl_memory.h" /* The last #include file should be: */ #include "memdebug.h" diff --git a/Source/CTest/Curl/hostthre.c b/Source/CTest/Curl/hostthre.c index 738efa5..7191418 100644 --- a/Source/CTest/Curl/hostthre.c +++ b/Source/CTest/Curl/hostthre.c @@ -85,7 +85,7 @@ #include "inet_ntop.h" -#include "memory.h" +#include "curl_memory.h" /* The last #include file should be: */ #include "memdebug.h" diff --git a/Source/CTest/Curl/http.c b/Source/CTest/Curl/http.c index 107c846..b7a9fe7 100644 --- a/Source/CTest/Curl/http.c +++ b/Source/CTest/Curl/http.c @@ -93,7 +93,7 @@ #include "share.h" #include "hostip.h" #include "http.h" -#include "memory.h" +#include "curl_memory.h" #define _MPRINTF_REPLACE /* use our functions only */ #include diff --git a/Source/CTest/Curl/http_chunks.c b/Source/CTest/Curl/http_chunks.c index baf2d66..02fdfc5 100644 --- a/Source/CTest/Curl/http_chunks.c +++ b/Source/CTest/Curl/http_chunks.c @@ -35,7 +35,7 @@ #include "content_encoding.h" #include "http.h" -#include "memory.h" +#include "curl_memory.h" #define _MPRINTF_REPLACE /* use our functions only */ #include diff --git a/Source/CTest/Curl/http_digest.c b/Source/CTest/Curl/http_digest.c index 20f5dc4..0e200fc 100644 --- a/Source/CTest/Curl/http_digest.c +++ b/Source/CTest/Curl/http_digest.c @@ -38,7 +38,7 @@ #include "http_digest.h" #include "strtok.h" #include "url.h" /* for Curl_safefree() */ -#include "memory.h" +#include "curl_memory.h" #define _MPRINTF_REPLACE /* use our functions only */ #include diff --git a/Source/CTest/Curl/http_negotiate.c b/Source/CTest/Curl/http_negotiate.c index 43f1da4..62a23f1 100644 --- a/Source/CTest/Curl/http_negotiate.c +++ b/Source/CTest/Curl/http_negotiate.c @@ -41,7 +41,7 @@ #include "strequal.h" #include "base64.h" #include "http_negotiate.h" -#include "memory.h" +#include "curl_memory.h" #define _MPRINTF_REPLACE /* use our functions only */ #include diff --git a/Source/CTest/Curl/http_ntlm.c b/Source/CTest/Curl/http_ntlm.c index dc31e83..fe0b653 100644 --- a/Source/CTest/Curl/http_ntlm.c +++ b/Source/CTest/Curl/http_ntlm.c @@ -46,7 +46,7 @@ #include "base64.h" #include "http_ntlm.h" #include "url.h" -#include "memory.h" +#include "curl_memory.h" #define _MPRINTF_REPLACE /* use our functions only */ #include diff --git a/Source/CTest/Curl/if2ip.c b/Source/CTest/Curl/if2ip.c index 0587951..594e74c 100644 --- a/Source/CTest/Curl/if2ip.c +++ b/Source/CTest/Curl/if2ip.c @@ -73,7 +73,7 @@ #endif #include "if2ip.h" -#include "memory.h" +#include "curl_memory.h" /* The last #include file should be: */ #include "memdebug.h" diff --git a/Source/CTest/Curl/krb4.c b/Source/CTest/Curl/krb4.c index 904ca77..50467e3 100644 --- a/Source/CTest/Curl/krb4.c +++ b/Source/CTest/Curl/krb4.c @@ -60,7 +60,7 @@ #include "ftp.h" #include "sendf.h" #include "krb4.h" -#include "memory.h" +#include "curl_memory.h" #if defined(HAVE_INET_NTOA_R) && !defined(HAVE_INET_NTOA_R_DECL) #include "inet_ntoa_r.h" diff --git a/Source/CTest/Curl/ldap.c b/Source/CTest/Curl/ldap.c index 8a87664..62e5b26 100644 --- a/Source/CTest/Curl/ldap.c +++ b/Source/CTest/Curl/ldap.c @@ -56,7 +56,7 @@ #include "strequal.h" #include "strtok.h" #include "ldap.h" -#include "memory.h" +#include "curl_memory.h" #define _MPRINTF_REPLACE /* use our functions only */ #include diff --git a/Source/CTest/Curl/llist.c b/Source/CTest/Curl/llist.c index 9618486..90ac1c8 100644 --- a/Source/CTest/Curl/llist.c +++ b/Source/CTest/Curl/llist.c @@ -27,7 +27,7 @@ #include #include "llist.h" -#include "memory.h" +#include "curl_memory.h" /* this must be the last include file */ #include "memdebug.h" diff --git a/Source/CTest/Curl/memdebug.c b/Source/CTest/Curl/memdebug.c index f5ef34d..799fe7c 100644 --- a/Source/CTest/Curl/memdebug.c +++ b/Source/CTest/Curl/memdebug.c @@ -42,7 +42,7 @@ #endif #define MEMDEBUG_NODEFINES /* don't redefine the standard functions */ -#include "memory.h" +#include "curl_memory.h" #include "memdebug.h" struct memdebug { diff --git a/Source/CTest/Curl/memory.h b/Source/CTest/Curl/memory.h deleted file mode 100644 index 4e32a67..0000000 --- a/Source/CTest/Curl/memory.h +++ /dev/null @@ -1,50 +0,0 @@ -#ifndef _CURL_MEMORY_H -#define _CURL_MEMORY_H -/*************************************************************************** - * _ _ ____ _ - * Project ___| | | | _ \| | - * / __| | | | |_) | | - * | (__| |_| | _ <| |___ - * \___|\___/|_| \_\_____| - * - * Copyright (C) 1998 - 2004, Daniel Stenberg, , et al. - * - * This software is licensed as described in the file COPYING, which - * you should have received as part of this distribution. The terms - * are also available at http://curl.haxx.se/docs/copyright.html. - * - * You may opt to use, copy, modify, merge, publish, distribute and/or sell - * copies of the Software, and permit persons to whom the Software is - * furnished to do so, under the terms of the COPYING file. - * - * This software is distributed on an "AS IS" basis, WITHOUT WARRANTY OF ANY - * KIND, either express or implied. - * - * $Id$ - ***************************************************************************/ - -#include /* for the typedefs */ - -extern curl_malloc_callback Curl_cmalloc; -extern curl_free_callback Curl_cfree; -extern curl_realloc_callback Curl_crealloc; -extern curl_strdup_callback Curl_cstrdup; -extern curl_calloc_callback Curl_ccalloc; - -#ifndef CURLDEBUG -/* Only do this define-mania if we're not using the memdebug system, as that - has preference on this magic. */ -#undef strdup -#define strdup(ptr) Curl_cstrdup(ptr) -#undef malloc -#define malloc(size) Curl_cmalloc(size) -#undef calloc -#define calloc(nbelem,size) Curl_ccalloc(nbelem, size) -#undef realloc -#define realloc(ptr,size) Curl_crealloc(ptr, size) -#undef free -#define free(ptr) Curl_cfree(ptr) - -#endif - -#endif /* _CURL_MEMORY_H */ diff --git a/Source/CTest/Curl/mprintf.c b/Source/CTest/Curl/mprintf.c index 9135a13..14eb40b 100644 --- a/Source/CTest/Curl/mprintf.c +++ b/Source/CTest/Curl/mprintf.c @@ -55,7 +55,7 @@ #define ENABLE_64BIT #endif -#include "memory.h" +#include "curl_memory.h" /* The last #include file should be: */ #include "memdebug.h" diff --git a/Source/CTest/Curl/multi.c b/Source/CTest/Curl/multi.c index 12b987f..c2c536d 100644 --- a/Source/CTest/Curl/multi.c +++ b/Source/CTest/Curl/multi.c @@ -42,7 +42,7 @@ #include "url.h" #include "connect.h" #include "progress.h" -#include "memory.h" +#include "curl_memory.h" /* The last #include file should be: */ #include "memdebug.h" diff --git a/Source/CTest/Curl/netrc.c b/Source/CTest/Curl/netrc.c index 950beb0..770bfb5 100644 --- a/Source/CTest/Curl/netrc.c +++ b/Source/CTest/Curl/netrc.c @@ -45,7 +45,7 @@ #include "strequal.h" #include "strtok.h" -#include "memory.h" +#include "curl_memory.h" #define _MPRINTF_REPLACE /* use our functions only */ #include diff --git a/Source/CTest/Curl/nwlib.c b/Source/CTest/Curl/nwlib.c index b0eea56..a999dfd 100644 --- a/Source/CTest/Curl/nwlib.c +++ b/Source/CTest/Curl/nwlib.c @@ -30,7 +30,7 @@ #include #include -#include "memory.h" +#include "curl_memory.h" #include "memdebug.h" typedef struct diff --git a/Source/CTest/Curl/security.c b/Source/CTest/Curl/security.c index 3b2a392..861f953 100644 --- a/Source/CTest/Curl/security.c +++ b/Source/CTest/Curl/security.c @@ -58,7 +58,7 @@ #include "base64.h" #include "sendf.h" #include "ftp.h" -#include "memory.h" +#include "curl_memory.h" /* The last #include file should be: */ #include "memdebug.h" diff --git a/Source/CTest/Curl/sendf.c b/Source/CTest/Curl/sendf.c index 7d0f71d..89c2665 100644 --- a/Source/CTest/Curl/sendf.c +++ b/Source/CTest/Curl/sendf.c @@ -52,7 +52,7 @@ #include "security.h" #endif #include -#include "memory.h" +#include "curl_memory.h" /* The last #include file should be: */ #include "memdebug.h" diff --git a/Source/CTest/Curl/share.c b/Source/CTest/Curl/share.c index 5c01845..1022d97 100644 --- a/Source/CTest/Curl/share.c +++ b/Source/CTest/Curl/share.c @@ -28,7 +28,7 @@ #include #include "urldata.h" #include "share.h" -#include "memory.h" +#include "curl_memory.h" /* The last #include file should be: */ #include "memdebug.h" diff --git a/Source/CTest/Curl/ssluse.c b/Source/CTest/Curl/ssluse.c index d5aaee5..04d1c94 100644 --- a/Source/CTest/Curl/ssluse.c +++ b/Source/CTest/Curl/ssluse.c @@ -54,7 +54,7 @@ #include #include -#include "memory.h" +#include "curl_memory.h" /* The last #include file should be: */ #include "memdebug.h" diff --git a/Source/CTest/Curl/telnet.c b/Source/CTest/Curl/telnet.c index b0f74bb..cc020c0 100644 --- a/Source/CTest/Curl/telnet.c +++ b/Source/CTest/Curl/telnet.c @@ -81,7 +81,7 @@ #define TELCMDS #include "arpa_telnet.h" -#include "memory.h" +#include "curl_memory.h" /* The last #include file should be: */ #include "memdebug.h" diff --git a/Source/CTest/Curl/transfer.c b/Source/CTest/Curl/transfer.c index 93df4c5..c2a60fe 100644 --- a/Source/CTest/Curl/transfer.c +++ b/Source/CTest/Curl/transfer.c @@ -101,7 +101,7 @@ #include "http_ntlm.h" #include "http_negotiate.h" #include "share.h" -#include "memory.h" +#include "curl_memory.h" #define _MPRINTF_REPLACE /* use our functions only */ #include diff --git a/Source/CTest/Curl/url.c b/Source/CTest/Curl/url.c index 6fff8bf..89dcf0f 100644 --- a/Source/CTest/Curl/url.c +++ b/Source/CTest/Curl/url.c @@ -145,7 +145,7 @@ void idn_free (void *ptr); /* prototype from idn-free.h, not provided by #ifdef HAVE_KRB4 #include "security.h" #endif -#include "memory.h" +#include "curl_memory.h" /* The last #include file should be: */ #include "memdebug.h" -- cgit v0.12