about summary refs log tree commit diff
path: root/inet
diff options
context:
space:
mode:
authorRoland McGrath <roland@hack.frob.com>2012-08-16 15:38:45 -0700
committerRoland McGrath <roland@hack.frob.com>2012-08-16 15:38:45 -0700
commit86466cd930d045a44cb7e85398660d9842e463c6 (patch)
tree74d46e57df979447a022296b2878a6a0efa61162 /inet
parentc3c8283c06a96d981b4a4aaef246fadde7ddef1e (diff)
downloadglibc-86466cd930d045a44cb7e85398660d9842e463c6.tar.gz
glibc-86466cd930d045a44cb7e85398660d9842e463c6.tar.xz
glibc-86466cd930d045a44cb7e85398660d9842e463c6.zip
Do not pollute name space with internal_*netgrent functions.
Diffstat (limited to 'inet')
-rw-r--r--inet/getnetgrent_r.c38
-rw-r--r--inet/netgroup.h14
2 files changed, 23 insertions, 29 deletions
diff --git a/inet/getnetgrent_r.c b/inet/getnetgrent_r.c
index 70cc14cd02..c57e7de178 100644
--- a/inet/getnetgrent_r.c
+++ b/inet/getnetgrent_r.c
@@ -171,19 +171,16 @@ __internal_setnetgrent_reuse (const char *group, struct __netgrent *datap,
   return status == NSS_STATUS_SUCCESS;
 }
 
-int internal_setnetgrent (const char *group, struct __netgrent *datap);
-libc_hidden_proto (internal_setnetgrent)
-
 int
-internal_setnetgrent (const char *group, struct __netgrent *datap)
+internal_function
+__internal_setnetgrent (const char *group, struct __netgrent *datap)
 {
   /* Free list of all netgroup names from last run.  */
   free_memory (datap);
 
   return __internal_setnetgrent_reuse (group, datap, &errno);
 }
-libc_hidden_def (internal_setnetgrent)
-strong_alias (internal_setnetgrent, __internal_setnetgrent)
+libc_hidden_def (__internal_setnetgrent)
 
 int
 setnetgrent (const char *group)
@@ -204,7 +201,7 @@ setnetgrent (const char *group)
 	goto out;
     }
 
-  result = internal_setnetgrent (group, &dataset);
+  result = __internal_setnetgrent (group, &dataset);
 
  out:
   __libc_lock_unlock (lock);
@@ -212,18 +209,15 @@ setnetgrent (const char *group)
   return result;
 }
 
-void internal_endnetgrent (struct __netgrent *datap);
-libc_hidden_proto (internal_endnetgrent)
-
 void
-internal_endnetgrent (struct __netgrent *datap)
+internal_function
+__internal_endnetgrent (struct __netgrent *datap)
 {
   endnetgrent_hook (datap);
   /* Now free list of all netgroup names from last run.  */
   free_memory (datap);
 }
-libc_hidden_def (internal_endnetgrent)
-strong_alias (internal_endnetgrent, __internal_endnetgrent)
+libc_hidden_def (__internal_endnetgrent)
 
 
 void
@@ -231,18 +225,12 @@ endnetgrent (void)
 {
   __libc_lock_lock (lock);
 
-  internal_endnetgrent (&dataset);
+  __internal_endnetgrent (&dataset);
 
   __libc_lock_unlock (lock);
 }
 
 
-int internal_getnetgrent_r (char **hostp, char **userp, char **domainp,
-			    struct __netgrent *datap,
-			    char *buffer, size_t buflen, int *errnop);
-libc_hidden_proto (internal_getnetgrent_r)
-
-
 static enum nss_status
 nscd_getnetgrent (struct __netgrent *datap, char *buffer, size_t buflen,
 		  int *errnop)
@@ -263,7 +251,8 @@ nscd_getnetgrent (struct __netgrent *datap, char *buffer, size_t buflen,
 
 
 int
-internal_getnetgrent_r (char **hostp, char **userp, char **domainp,
+internal_function
+__internal_getnetgrent_r (char **hostp, char **userp, char **domainp,
 			  struct __netgrent *datap,
 			  char *buffer, size_t buflen, int *errnop)
 {
@@ -361,8 +350,7 @@ internal_getnetgrent_r (char **hostp, char **userp, char **domainp,
 
   return status == NSS_STATUS_SUCCESS ? 1 : 0;
 }
-libc_hidden_def (internal_getnetgrent_r)
-strong_alias (internal_getnetgrent_r, __internal_getnetgrent_r)
+libc_hidden_def (__internal_getnetgrent_r)
 
 /* The real entry point.  */
 int
@@ -373,8 +361,8 @@ __getnetgrent_r (char **hostp, char **userp, char **domainp,
 
   __libc_lock_lock (lock);
 
-  status = internal_getnetgrent_r (hostp, userp, domainp, &dataset,
-				   buffer, buflen, &errno);
+  status = __internal_getnetgrent_r (hostp, userp, domainp, &dataset,
+                                     buffer, buflen, &errno);
 
   __libc_lock_unlock (lock);
 
diff --git a/inet/netgroup.h b/inet/netgroup.h
index 2c0d1a4831..f3797a698d 100644
--- a/inet/netgroup.h
+++ b/inet/netgroup.h
@@ -1,5 +1,5 @@
 /* Internal header for netgroup related functions.
-   Copyright (C) 1996, 1997, 2004 Free Software Foundation, Inc.
+   Copyright (C) 1996-2012 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
 
    The GNU C Library is free software; you can redistribute it and/or
@@ -70,10 +70,16 @@ struct __netgrent
 
 /* The internal netgroup handling functions might be called from outside.  */
 extern int __internal_setnetgrent (const char *group,
-				   struct __netgrent *datap);
-extern void __internal_endnetgrent (struct __netgrent *datap);
+				   struct __netgrent *datap)
+  internal_function;
+libc_hidden_proto (__internal_setnetgrent)
+extern void __internal_endnetgrent (struct __netgrent *datap)
+  internal_function;
+libc_hidden_proto (__internal_endnetgrent)
 extern int __internal_getnetgrent_r (char **hostp, char **userp,
 				     char **domainp, struct __netgrent *datap,
-				     char *buffer, size_t buflen, int *errnop);
+				     char *buffer, size_t buflen, int *errnop)
+  internal_function;
+libc_hidden_proto (__internal_getnetgrent_r)
 
 #endif /* netgroup.h */