From patchwork Mon Jun 21 11:46:54 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Florian Weimer X-Patchwork-Id: 43934 X-Patchwork-Delegate: azanella@linux.vnet.ibm.com Return-Path: X-Original-To: patchwork@sourceware.org Delivered-To: patchwork@sourceware.org Received: from server2.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id A7C183938380 for ; Mon, 21 Jun 2021 11:48:45 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org A7C183938380 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=sourceware.org; s=default; t=1624276125; bh=rn2adIpBM0LTZTHkhkdWydpk++NwsZ1K/uvflwb0fX4=; h=To:Subject:In-Reply-To:References:Date:List-Id:List-Unsubscribe: List-Archive:List-Post:List-Help:List-Subscribe:From:Reply-To: From; b=duSWQ23WGcQd6Xl9IBiq4+SI8iwE/hTV+XBr3n/VYGmJT0Dl8tsHCqpYbl9cjRbog qKEKPsZR7y5EKNRgRxiJC230Ni+U4xgqYVljq6Zh8w2kEvg9V+lKEEfmuNheD736EO WvtnFjYy3b3hETJyzqck3lLyPugHB44B0jxfIXbY= X-Original-To: libc-alpha@sourceware.org Delivered-To: libc-alpha@sourceware.org Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.133.124]) by sourceware.org (Postfix) with ESMTP id DA81E3938C00 for ; Mon, 21 Jun 2021 11:46:59 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.1 sourceware.org DA81E3938C00 Received: from mimecast-mx01.redhat.com (mimecast-mx01.redhat.com [209.132.183.4]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-216-K9Gaa6TiP0-aq3mDiwr1DA-1; Mon, 21 Jun 2021 07:46:57 -0400 X-MC-Unique: K9Gaa6TiP0-aq3mDiwr1DA-1 Received: from smtp.corp.redhat.com (int-mx07.intmail.prod.int.phx2.redhat.com [10.5.11.22]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id E4296801596 for ; Mon, 21 Jun 2021 11:46:56 +0000 (UTC) Received: from oldenburg.str.redhat.com (ovpn-115-60.ams2.redhat.com [10.36.115.60]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 46A4C10016F5 for ; Mon, 21 Jun 2021 11:46:56 +0000 (UTC) To: libc-alpha@sourceware.org Subject: [PATCH 2/3] login: Rework hidden prototypes for __setutent, __utmpname, __endutent In-Reply-To: References: X-From-Line: 16b3eb68f21df794606763f02c37bd114d3e0b74 Mon Sep 17 00:00:00 2001 Message-Id: <16b3eb68f21df794606763f02c37bd114d3e0b74.1624275874.git.fweimer@redhat.com> Date: Mon, 21 Jun 2021 13:46:54 +0200 User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.2 (gnu/linux) MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.84 on 10.5.11.22 X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com X-Spam-Status: No, score=-12.7 required=5.0 tests=BAYES_00, DKIMWL_WL_HIGH, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, GIT_PATCH_0, RCVD_IN_DNSWL_LOW, RCVD_IN_MSPIKE_H4, RCVD_IN_MSPIKE_WL, SPF_HELO_NONE, SPF_PASS, TXREP autolearn=ham autolearn_force=no version=3.4.2 X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on server2.sourceware.org X-BeenThere: libc-alpha@sourceware.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Libc-alpha mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-Patchwork-Original-From: Florian Weimer via Libc-alpha From: Florian Weimer Reply-To: Florian Weimer Errors-To: libc-alpha-bounces+patchwork=sourceware.org@sourceware.org Sender: "Libc-alpha" Replace attribute_hidden with a regular combination of libc_hidden_proto and libc_hidden_def. Reviewed-by: Adhemerval Zanella --- include/utmp.h | 9 ++++++--- login/getutent_r.c | 2 ++ login/utmpname.c | 1 + 3 files changed, 9 insertions(+), 3 deletions(-) diff --git a/include/utmp.h b/include/utmp.h index 374184e9b2..e8162bd08d 100644 --- a/include/utmp.h +++ b/include/utmp.h @@ -6,11 +6,14 @@ /* Now define the internal interfaces. */ extern void __updwtmp (const char *__wtmp_file, const struct utmp *__utmp); libc_hidden_proto (__updwtmp) -extern int __utmpname (const char *__file) attribute_hidden; +extern int __utmpname (const char *__file); +libc_hidden_proto (__utmpname) extern struct utmp *__getutent (void); libc_hidden_proto (__getutent) -extern void __setutent (void) attribute_hidden; -extern void __endutent (void) attribute_hidden; +extern void __setutent (void); +libc_hidden_proto (__setutent) +extern void __endutent (void); +libc_hidden_proto (__endutent) extern struct utmp *__getutid (const struct utmp *__id); libc_hidden_proto (__getutid) extern struct utmp *__getutline (const struct utmp *__line); diff --git a/login/getutent_r.c b/login/getutent_r.c index 0af48acec8..58d3d5fd0c 100644 --- a/login/getutent_r.c +++ b/login/getutent_r.c @@ -36,6 +36,7 @@ __setutent (void) __libc_lock_unlock (__libc_utmp_lock); } +libc_hidden_def (__setutent) weak_alias (__setutent, setutent) @@ -82,4 +83,5 @@ __endutent (void) __libc_lock_unlock (__libc_utmp_lock); } +libc_hidden_def (__endutent) weak_alias (__endutent, endutent) diff --git a/login/utmpname.c b/login/utmpname.c index c85c27fe68..a645445e8a 100644 --- a/login/utmpname.c +++ b/login/utmpname.c @@ -72,4 +72,5 @@ done: __libc_lock_unlock (__libc_utmp_lock); return result; } +libc_hidden_def (__utmpname) weak_alias (__utmpname, utmpname)