[syslinux:elflink] elflink: fix the global naming for lmalloc
syslinux-bot for Feng Tang
feng.tang at intel.com
Thu Aug 12 21:03:12 PDT 2010
Commit-ID: 9333426bffb6bb3f1b6193369097fb4bcaee64ad
Gitweb: http://syslinux.zytor.com/commit/9333426bffb6bb3f1b6193369097fb4bcaee64ad
Author: Feng Tang <feng.tang at intel.com>
AuthorDate: Tue, 8 Jun 2010 16:51:45 +0800
Committer: Feng Tang <feng.tang at intel.com>
CommitDate: Tue, 20 Jul 2010 11:10:03 +0800
elflink: fix the global naming for lmalloc
core and com32 both have their lmalloc definition, change com32's
from lmalloc to clmalloc
---
com32/include/com32.h | 2 +-
com32/lib/Makefile | 4 ++++
com32/lib/lmalloc.c | 2 +-
com32/lib/lstrdup.c | 2 +-
4 files changed, 7 insertions(+), 3 deletions(-)
diff --git a/com32/include/com32.h b/com32/include/com32.h
index 6b14208..f49f9ea 100644
--- a/com32/include/com32.h
+++ b/com32/include/com32.h
@@ -120,7 +120,7 @@ extern const com32sys_t __com32_zero_regs;
/*
* Lowmem allocation functions
*/
-void *lmalloc(size_t);
+void *clmalloc(size_t);
void *lzalloc(size_t);
void lfree(void *);
char *lstrdup(const char *);
diff --git a/com32/lib/Makefile b/com32/lib/Makefile
index c7e7e7d..41ae34c 100755
--- a/com32/lib/Makefile
+++ b/com32/lib/Makefile
@@ -125,6 +125,10 @@ LIBOTHER_OBJS = \
asprintf.o vasprintf.o strlcpy.o strlcat.o \
vsscanf.o zalloc.o \
\
+ lmalloc.o lstrdup.o \
+ \
+ dprintf.o vdprintf.o \
+ \
sys/readdir.o getcwd.o chdir.o fdopendir.o \
\
libgcc/__ashldi3.o libgcc/__udivdi3.o \
diff --git a/com32/lib/lmalloc.c b/com32/lib/lmalloc.c
index a646556..69438bd 100644
--- a/com32/lib/lmalloc.c
+++ b/com32/lib/lmalloc.c
@@ -31,7 +31,7 @@
#include <string.h>
#include <syslinux/pmapi.h>
-void *lmalloc(size_t size)
+void *clmalloc(size_t size)
{
void *p;
p = __com32.cs_pm->lmalloc(size);
diff --git a/com32/lib/lstrdup.c b/com32/lib/lstrdup.c
index d11efe7..6747ef3 100644
--- a/com32/lib/lstrdup.c
+++ b/com32/lib/lstrdup.c
@@ -9,7 +9,7 @@
char *lstrdup(const char *s)
{
int l = strlen(s) + 1;
- char *d = lmalloc(l);
+ char *d = clmalloc(l);
if (d)
memcpy(d, s, l);
More information about the Syslinux-commits
mailing list