From dda48146a2781fe685eeb9dc5194d142ee5ca0ef Mon Sep 17 00:00:00 2001 From: Andrew Bartlett Date: Mon, 19 Nov 2012 23:25:45 +1100 Subject: heimdal_build: Try again to sort out the strerror_r mess Reviewed-by: Stefan Metzmacher --- lib/replace/replace.c | 2 +- lib/replace/replace.h | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) (limited to 'lib/replace') diff --git a/lib/replace/replace.c b/lib/replace/replace.c index 8f1315a3a5..37edb310c5 100644 --- a/lib/replace/replace.c +++ b/lib/replace/replace.c @@ -785,7 +785,7 @@ char *rep_get_current_dir_name(void) } #endif -#if !defined(HAVE_STRERROR_R) && !defined(strerror_r) +#ifndef HAVE_STRERROR_R int rep_strerror_r(int errnum, char *buf, size_t buflen) { char *s = strerror(errnum); diff --git a/lib/replace/replace.h b/lib/replace/replace.h index 62172a9a12..9774da4673 100644 --- a/lib/replace/replace.h +++ b/lib/replace/replace.h @@ -570,7 +570,8 @@ ssize_t rep_pwrite(int __fd, const void *__buf, size_t __nbytes, off_t __offset) char *rep_get_current_dir_name(void); #endif -#if !defined(HAVE_STRERROR_R) && !defined(strerror_r) +#ifndef HAVE_STRERROR_R +#define strerror_r rep_strerror_r int rep_strerror_r(int errnum, char *buf, size_t buflen); #endif -- cgit