summaryrefslogtreecommitdiff
path: root/src/common
diff options
context:
space:
mode:
authorgepard1984 <gepard1984@54d463be-8e91-2dee-dedb-b68131a5f0ec>2012-02-14 15:29:00 +0000
committergepard1984 <gepard1984@54d463be-8e91-2dee-dedb-b68131a5f0ec>2012-02-14 15:29:00 +0000
commit27abf1bcb19ef14ec08dc7916cd383e3f045c88b (patch)
treea939536eb04ffe940f656d1f492f8d12083e39cc /src/common
parent4c1423ea04f98647576a952be6adbc1b0d8ce2cf (diff)
downloadhercules-27abf1bcb19ef14ec08dc7916cd383e3f045c88b.tar.gz
hercules-27abf1bcb19ef14ec08dc7916cd383e3f045c88b.tar.bz2
hercules-27abf1bcb19ef14ec08dc7916cd383e3f045c88b.tar.xz
hercules-27abf1bcb19ef14ec08dc7916cd383e3f045c88b.zip
Removed deprecated memory manager macros (follow-up to r14916).
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@15581 54d463be-8e91-2dee-dedb-b68131a5f0ec
Diffstat (limited to 'src/common')
-rw-r--r--src/common/grfio.c12
-rw-r--r--src/common/malloc.h5
-rw-r--r--src/common/strlib.c2
3 files changed, 7 insertions, 12 deletions
diff --git a/src/common/grfio.c b/src/common/grfio.c
index 88642cfe5..cc0e1bb42 100644
--- a/src/common/grfio.c
+++ b/src/common/grfio.c
@@ -406,7 +406,7 @@ void* grfio_reads(const char* fname, int* size)
fseek(in,0,SEEK_END);
declen = ftell(in);
fseek(in,0,SEEK_SET);
- buf2 = (unsigned char *)aMallocA(declen+1); // +1 for resnametable zero-termination
+ buf2 = (unsigned char *)aMalloc(declen+1); // +1 for resnametable zero-termination
fileReadCount = fread(buf2, 1, declen, in);
fclose(in);
@@ -430,13 +430,13 @@ void* grfio_reads(const char* fname, int* size)
FILE* in = fopen(grfname, "rb");
if( in != NULL )
{
- unsigned char *buf = (unsigned char *)aMallocA(entry->srclen_aligned);
+ unsigned char *buf = (unsigned char *)aMalloc(entry->srclen_aligned);
size_t fileReadCount;
fseek(in, entry->srcpos, 0);
fileReadCount = fread(buf, 1, entry->srclen_aligned, in);
fclose(in);
- buf2 = (unsigned char *)aMallocA(entry->declen+1); // +1 for resnametable zero-termination
+ buf2 = (unsigned char *)aMalloc(entry->declen+1); // +1 for resnametable zero-termination
if( entry->type & FILELIST_TYPE_FILE )
{// file
uLongf len;
@@ -538,7 +538,7 @@ static int grfio_entryread(const char* grfname, int gentry)
{// ****** Grf version 01xx ******
size_t fileReadCount;
list_size = grf_size - ftell(fp);
- grf_filelist = (unsigned char *) aMallocA(list_size);
+ grf_filelist = (unsigned char *) aMalloc(list_size);
fileReadCount = fread(grf_filelist,1,list_size,fp);
fclose(fp);
@@ -604,8 +604,8 @@ static int grfio_entryread(const char* grfname, int gentry)
return 4;
}
- rBuf = (unsigned char *)aMallocA(rSize); // Get a Read Size
- grf_filelist = (unsigned char *)aMallocA(eSize); // Get a Extend Size
+ rBuf = (unsigned char *)aMalloc(rSize); // Get a Read Size
+ grf_filelist = (unsigned char *)aMalloc(eSize); // Get a Extend Size
fileReadCount = fread(rBuf,1,rSize,fp);
fclose(fp);
decode_zip(grf_filelist, &eSize, rBuf, rSize); // Decode function
diff --git a/src/common/malloc.h b/src/common/malloc.h
index 5f8191d92..6b4e8e5c4 100644
--- a/src/common/malloc.h
+++ b/src/common/malloc.h
@@ -61,11 +61,6 @@
#endif
-// deprecated, do not use
-#define aMallocA aMalloc
-#define aCallocA aCalloc
-#define CREATE_A CREATE
-
/////////////// Buffer Creation /////////////////
// Full credit for this goes to Shinomori [Ajarn]
diff --git a/src/common/strlib.c b/src/common/strlib.c
index 7f79a5ef0..dfacbf136 100644
--- a/src/common/strlib.c
+++ b/src/common/strlib.c
@@ -1051,7 +1051,7 @@ StringBuf* StringBuf_Malloc()
void StringBuf_Init(StringBuf* self)
{
self->max_ = 1024;
- self->ptr_ = self->buf_ = (char*)aMallocA(self->max_ + 1);
+ self->ptr_ = self->buf_ = (char*)aMalloc(self->max_ + 1);
}
/// Appends the result of printf to the StringBuf