summaryrefslogtreecommitdiff
path: root/src/common/malloc.c
diff options
context:
space:
mode:
authorFlavioJS <FlavioJS@54d463be-8e91-2dee-dedb-b68131a5f0ec>2008-11-22 15:44:17 +0000
committerFlavioJS <FlavioJS@54d463be-8e91-2dee-dedb-b68131a5f0ec>2008-11-22 15:44:17 +0000
commit951a736ea97701dcde48c6085a596de96bafce45 (patch)
tree4aa30fc79780452937ea476e68b1a3013bc9c57c /src/common/malloc.c
parent82ed8e76484c53edb394191d95da9d1fad77bbe1 (diff)
downloadhercules-951a736ea97701dcde48c6085a596de96bafce45.tar.gz
hercules-951a736ea97701dcde48c6085a596de96bafce45.tar.bz2
hercules-951a736ea97701dcde48c6085a596de96bafce45.tar.xz
hercules-951a736ea97701dcde48c6085a596de96bafce45.zip
* Hunted down the simpler 64bit pointer truncations.
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@13380 54d463be-8e91-2dee-dedb-b68131a5f0ec
Diffstat (limited to 'src/common/malloc.c')
-rw-r--r--src/common/malloc.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/common/malloc.c b/src/common/malloc.c
index c64f757bd..b566e689f 100644
--- a/src/common/malloc.c
+++ b/src/common/malloc.c
@@ -428,7 +428,7 @@ void _mfree(void *ptr, const char *file, int line, const char *func )
hash_unfill[ block->unit_hash ] = block;
}
head->size = block->unit_unfill;
- block->unit_unfill = (unsigned short)(((unsigned long)head - (unsigned long)block->data) / block->unit_size);
+ block->unit_unfill = (unsigned short)(((uintptr)head - (uintptr)block->data) / block->unit_size);
}
}
}