acl-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Acl-devel] [PATCH acl 1/2] mark libmisc funcs as hidden so they are not


From: Mike Frysinger
Subject: [Acl-devel] [PATCH acl 1/2] mark libmisc funcs as hidden so they are not exported
Date: Tue, 12 Aug 2014 08:38:30 -0400

---
 include/misc.h  | 17 +++++++++++++----
 libacl/libobj.h |  9 +--------
 2 files changed, 14 insertions(+), 12 deletions(-)

diff --git a/include/misc.h b/include/misc.h
index a4fa70e..f5c0dae 100644
--- a/include/misc.h
+++ b/include/misc.h
@@ -18,14 +18,23 @@
 #ifndef __MISC_H
 #define __MISC_H
 
+#include "config.h"
+
 #include <stdio.h>
 
-extern int high_water_alloc(void **buf, size_t *bufsize, size_t newsize);
+/* Mark library internal functions as hidden */
+#if defined(HAVE_VISIBILITY_ATTRIBUTE)
+# define hidden __attribute__((visibility("hidden")))
+#else
+# define hidden /* hidden */
+#endif
+
+hidden int high_water_alloc(void **buf, size_t *bufsize, size_t newsize);
 
-extern const char *quote(const char *str, const char *quote_chars);
-extern char *unquote(char *str);
+hidden const char *quote(const char *str, const char *quote_chars);
+hidden char *unquote(char *str);
 
-extern char *next_line(FILE *file);
+hidden char *next_line(FILE *file);
 
 #ifdef ENABLE_NLS
 # include <libintl.h>
diff --git a/libacl/libobj.h b/libacl/libobj.h
index 5480a0e..c41d5f9 100644
--- a/libacl/libobj.h
+++ b/libacl/libobj.h
@@ -20,14 +20,7 @@
 
 #include <stdlib.h>
 
-#include "config.h"
-
-/* Mark library internal functions as hidden */
-#if defined(HAVE_VISIBILITY_ATTRIBUTE)
-# define hidden __attribute__((visibility("hidden")))
-#else
-# define hidden /* hidden */
-#endif
+#include "misc.h"
 
 /* Ugly pointer manipulation */
 
-- 
2.0.0




reply via email to

[Prev in Thread] Current Thread [Next in Thread]