]> git.ipfire.org Git - thirdparty/glibc.git/commitdiff
NSS: Do not use internal_function for functions with hidden aliases
authorFlorian Weimer <fweimer@redhat.com>
Sun, 13 Aug 2017 19:10:56 +0000 (21:10 +0200)
committerFlorian Weimer <fweimer@redhat.com>
Sun, 13 Aug 2017 19:10:56 +0000 (21:10 +0200)
Such functions are called across DSO boundaries and should not
use a non-standard ABI.

ChangeLog
grp/grp-merge.c
grp/grp-merge.h
inet/getnetgrent_r.c
inet/netgroup.h
nss/XXX-lookup.c
nss/getXXbyYY_r.c
nss/getXXent_r.c
nss/nsswitch.h

index 3ad08f30301ef668ea38302254a1f7cbcea6eaf0..d446b10506f07c973f8202d0af7befcba4bfd0a4 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,17 @@
+2017-08-13  Florian Weimer  <fweimer@redhat.com>
+
+       * grp/grp-merge.h (__copy_grp, __merge_grp): Remove
+       internal_function.
+       * grp/grp-merge.c (__copy_grp, __merge_grp): Likewise.
+       * inet/netgroup.h (__internal_setnetgrent)
+       (__internal_endnetgrent,__internal_getnetgrent_r): Likewise.
+       * inet/getnetgrent_r.c (__internal_setnetgrent)
+       (__internal_endnetgrent,__internal_getnetgrent_r): Likewise.
+       * nss/XXX-lookup.c (DB_LOOKUP_FCT, DB_COMPAT_FCT): Likewise.
+       * nss/getXXbyYY_r.c (DB_LOOKUP_FCT): Likewise.
+       * nss/getXXent_r.c (DB_LOOKUP_FCT): Likewise.
+       * nss/nsswitch.h (db_lookup_function): Likewise.
+
 2017-08-13  Florian Weimer  <fweimer@redhat.com>
 
        * debug/fortify_fail.c (__fortify_fail, __fortify_fail_abort):
index 035e7a604bbb71e0c3b282f62e847d43a03ed85e..df7260857d334599f1a21fa58c2a53c6ba6f7065 100644 (file)
@@ -36,7 +36,6 @@
   })
 
 int
-internal_function
 __copy_grp (const struct group srcgrp, const size_t buflen,
            struct group *destgrp, char *destbuf, char **endptr)
 {
@@ -117,7 +116,6 @@ libc_hidden_def (__copy_grp)
 /* Check that the name, GID and passwd fields match, then
    copy in the gr_mem array.  */
 int
-internal_function
 __merge_grp (struct group *savedgrp, char *savedbuf, char *savedend,
             size_t buflen, struct group *mergegrp, char *mergebuf)
 {
index 1ad9b9a53971549585af41cb84e5d69aee80d46b..f6ee83885baaa831e32a616adc8afac0495b4d50 100644 (file)
    calling function must free(newbuf).  */
 int
 __copy_grp (const struct group srcgrp, const size_t buflen,
-           struct group *destgrp, char *destbuf, char **endptr)
-           internal_function;
+           struct group *destgrp, char *destbuf, char **endptr);
 
 /* Merge the member lists of two grp structs together.  */
 int
 __merge_grp (struct group *savedgrp, char *savedbuf, char *savedend,
-            size_t buflen, struct group *mergegrp, char *mergebuf)
-            internal_function;
+            size_t buflen, struct group *mergegrp, char *mergebuf);
 
 #endif /* _GRP_MERGE_H */
index 1b4eb65b89ac8305695bdba4e416abfc29526596..a8fc51c1b610850b4cdbd51134c0100f68be92d2 100644 (file)
@@ -172,7 +172,6 @@ __internal_setnetgrent_reuse (const char *group, struct __netgrent *datap,
 }
 
 int
-internal_function
 __internal_setnetgrent (const char *group, struct __netgrent *datap)
 {
   /* Free list of all netgroup names from last run.  */
@@ -214,7 +213,6 @@ setnetgrent (const char *group)
 }
 
 void
-internal_function
 __internal_endnetgrent (struct __netgrent *datap)
 {
   endnetgrent_hook (datap);
@@ -263,7 +261,6 @@ nscd_getnetgrent (struct __netgrent *datap, char *buffer, size_t buflen,
 #endif
 
 int
-internal_function
 __internal_getnetgrent_r (char **hostp, char **userp, char **domainp,
                          struct __netgrent *datap,
                          char *buffer, size_t buflen, int *errnop)
index 9ad9dfe1444d2f37c51ffedaf31e409432cffbe1..630d2b768a9324b8315ad2cfde88fe88552b1d74 100644 (file)
@@ -70,16 +70,13 @@ struct __netgrent
 
 /* The internal netgroup handling functions might be called from outside.  */
 extern int __internal_setnetgrent (const char *group,
-                                  struct __netgrent *datap)
-  internal_function;
+                                  struct __netgrent *datap);
 libc_hidden_proto (__internal_setnetgrent)
-extern void __internal_endnetgrent (struct __netgrent *datap)
-  internal_function;
+extern void __internal_endnetgrent (struct __netgrent *datap);
 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)
-  internal_function;
+                                    char *buffer, size_t buflen, int *errnop);
 libc_hidden_proto (__internal_getnetgrent_r)
 
 #endif /* netgroup.h */
index 5a37fdae08dffaf39519d2e452b4e4ccce246551..972a2102bf98ba85a313efaecc6a9ba2dd4472dc 100644 (file)
 service_user *DATABASE_NAME_SYMBOL attribute_hidden;
 
 extern int DB_LOOKUP_FCT (service_user **ni, const char *fct_name,
-                         const char *fct2_name, void **fctp)
-  internal_function;
+                         const char *fct2_name, void **fctp);
 libc_hidden_proto (DB_LOOKUP_FCT)
 
 int
-internal_function
 DB_LOOKUP_FCT (service_user **ni, const char *fct_name, const char *fct2_name,
               void **fctp)
 {
@@ -79,7 +77,7 @@ libc_hidden_def (DB_LOOKUP_FCT)
 
 #ifndef NO_COMPAT
 int
-internal_function attribute_compat_text_section
+attribute_compat_text_section
 DB_COMPAT_FCT (service_user **ni, const char *fct_name, void **fctp)
 {
   return DB_LOOKUP_FCT (ni, fct_name, NULL, fctp);
index bce80e05dd2d176467809faf353828f50cf76eaf..c58481ef808a8f0622d926fe59faf675c095601c 100644 (file)
@@ -180,8 +180,7 @@ typedef enum nss_status (*lookup_function) (ADD_PARAMS, LOOKUP_TYPE *, char *,
 
 /* The lookup function for the first entry of this service.  */
 extern int DB_LOOKUP_FCT (service_user **nip, const char *name,
-                         const char *name2, void **fctp)
-     internal_function;
+                         const char *name2, void **fctp);
 libc_hidden_proto (DB_LOOKUP_FCT)
 
 
index 2710c1cd5135d81141658d05070c98a7d40fb9d3..66c38a52458da2ceff6aa880d33f657db1836025 100644 (file)
@@ -113,8 +113,7 @@ __libc_lock_define_initialized (static, lock)
 
 /* The lookup function for the first entry of this service.  */
 extern int DB_LOOKUP_FCT (service_user **nip, const char *name,
-                         const char *name2, void **fctp)
-     internal_function;
+                         const char *name2, void **fctp);
 libc_hidden_proto (DB_LOOKUP_FCT)
 \f
 void
index bd3fbcb08250c61c5987aca822e4775daec93d4d..7da90130ec7eb36eb48a6b47893a380e890b3818 100644 (file)
@@ -168,8 +168,7 @@ extern void __nss_disable_nscd (void (*) (size_t, struct traced_file *));
 
 
 typedef int (*db_lookup_function) (service_user **, const char *, const char *,
-                                  void **)
-     internal_function;
+                                  void **);
 typedef enum nss_status (*setent_function) (int);
 typedef enum nss_status (*endent_function) (void);
 typedef enum nss_status (*getent_function) (void *, char *, size_t,