From 6d2f28c0809a7ed7c68ff04bc2704656a59dbe36 Mon Sep 17 00:00:00 2001 From: Kurt Zeilenga Date: Wed, 18 Nov 1998 16:13:51 +0000 Subject: [PATCH] Protect strdup/memcmp from macro subsitution. Let compiler pick registers. --- libraries/liblutil/memcmp.c | 4 ++-- libraries/liblutil/strdup.c | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/libraries/liblutil/memcmp.c b/libraries/liblutil/memcmp.c index b2c575d955..99daac2d0b 100644 --- a/libraries/liblutil/memcmp.c +++ b/libraries/liblutil/memcmp.c @@ -6,10 +6,10 @@ * Memory Compare */ int -memcmp(const void *v1, const void *v2, int n) +(memcmp)(const void *v1, const void *v2, int n) { if (n != 0) { - register const unsigned char *s1=v1, *s2=v2; + const unsigned char *s1=v1, *s2=v2; do { if (*s1++ != *s2++) return (*--s1 - *--s2); diff --git a/libraries/liblutil/strdup.c b/libraries/liblutil/strdup.c index 31baa12b30..27b0d81d54 100644 --- a/libraries/liblutil/strdup.c +++ b/libraries/liblutil/strdup.c @@ -6,7 +6,7 @@ #include #include "lutil.h" -char *strdup( const char *s ) +char *(strdup)( const char *s ) { char *p; -- 2.39.5