From de53effecc68ebbd13b1d8e9ce6b2651b3c5dd86 Mon Sep 17 00:00:00 2001 From: Davidlohr Bueso Date: Thu, 3 Feb 2011 12:09:00 -0300 Subject: [PATCH] Fix conflicts with glibc globals When compiling libvirt with GCC 3.4.6 the following warning is being triggered quite a lot: util/memory.h:60: warning: declaration of 'remove' shadows a global declaration /usr/include/stdio.h:175: warning: shadowed declaration is here Fix this by renaming the parameter to 'toremove'. --- AUTHORS | 1 + src/util/memory.h | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/AUTHORS b/AUTHORS index 175b2cfeb4..5e540ea681 100644 --- a/AUTHORS +++ b/AUTHORS @@ -148,6 +148,7 @@ Patches have also been contributed by: Juerg Haefliger Matthias Dahl Niels de Vos + Davidlohr Bueso [....send patches to get your name here....] diff --git a/src/util/memory.h b/src/util/memory.h index 750a6b0181..66b4c420fa 100644 --- a/src/util/memory.h +++ b/src/util/memory.h @@ -57,7 +57,7 @@ int virExpandN(void *ptrptr, size_t size, size_t *count, size_t add) int virResizeN(void *ptrptr, size_t size, size_t *alloc, size_t count, size_t desired) ATTRIBUTE_RETURN_CHECK ATTRIBUTE_NONNULL(1) ATTRIBUTE_NONNULL(3); -void virShrinkN(void *ptrptr, size_t size, size_t *count, size_t remove) +void virShrinkN(void *ptrptr, size_t size, size_t *count, size_t toremove) ATTRIBUTE_NONNULL(1) ATTRIBUTE_NONNULL(3); int virAllocVar(void *ptrptr, size_t struct_size, -- 2.47.2