From patchwork Sun Jun 14 16:38:08 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Joseph Myers X-Patchwork-Id: 484059 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from sourceware.org (server1.sourceware.org [209.132.180.131]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id C947A14027F for ; Mon, 15 Jun 2015 02:38:27 +1000 (AEST) Authentication-Results: ozlabs.org; dkim=pass (1024-bit key; unprotected) header.d=sourceware.org header.i=@sourceware.org header.b=Z1DKeTM3; dkim-atps=neutral DomainKey-Signature: a=rsa-sha1; c=nofws; d=sourceware.org; h=list-id :list-unsubscribe:list-subscribe:list-archive:list-post :list-help:sender:date:from:to:subject:message-id:mime-version :content-type; q=dns; s=default; b=tNuCOty1w1inggvaUx/LY7Q6C/r4t NmAP4Y9OQOABGG0RqM0dVmE8otILjAzenhRr8Nm5aJbdW/BtgsPeF8aORzLh6Inx S0cPOo6iq3QH6Fb7Xx+O8rNWmWj5Xp8U9V3MeQQD2MzOldkdhzWu64vMAGeS/8Kd ISAcZVN6WM4pBE= DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=sourceware.org; h=list-id :list-unsubscribe:list-subscribe:list-archive:list-post :list-help:sender:date:from:to:subject:message-id:mime-version :content-type; s=default; bh=0130JamuQ5w2lnMaIMBGiyG40X4=; b=Z1D KeTM3wcWzGABDtu/2OL2OzcBnIrCgCyNZgtj9TUxbwX6kEijBGyU22szsADlya/2 epu+T62xRpyLoJLvR0gJ063ULeIDjtmY7zrOmi2i3a59rUSt133qeoV0b9N2Ogqg ABAdD7cjan10ZRM8JFERBOJtGkRIUhY/8/uulqig= Received: (qmail 41953 invoked by alias); 14 Jun 2015 16:38:22 -0000 Mailing-List: contact libc-alpha-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Unsubscribe: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: libc-alpha-owner@sourceware.org Delivered-To: mailing list libc-alpha@sourceware.org Received: (qmail 41936 invoked by uid 89); 14 Jun 2015 16:38:21 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-2.3 required=5.0 tests=AWL, BAYES_00, RCVD_IN_DNSWL_LOW, SPF_PASS autolearn=ham version=3.3.2 X-HELO: relay1.mentorg.com Date: Sun, 14 Jun 2015 16:38:08 +0000 From: Joseph Myers To: Subject: Fix vsyslog namespace (bug 18533) Message-ID: User-Agent: Alpine 2.10 (DEB 1266 2009-07-14) MIME-Version: 1.0 syslog functions (in POSIX) bring in the strong symbol vsyslog (not in POSIX). This patch fixes this by changing this symbol from a strong alias to a weak alias. Tested for x86_64 and x86 (testsuite, and that installed stripped shared libraries are unchanged by the patch). (vsyslog becomes weak in the static libraries, which is what's needed; the particular macro sequence in use leaves it as strong in the shared libraries, hence those libraries being completely unchanged, but it doesn't generally matter whether symbols exported from the shared libraries are weak or strong.) 2015-06-14 Joseph Myers [BZ #18533] * misc/syslog.c (vsyslog): Define as a weak alias of __vsyslog, not a strong alias. * conform/Makefile (test-xfail-XOPEN2K8/syslog.h/linknamespace): Remove variable. diff --git a/conform/Makefile b/conform/Makefile index 9ad7601..567046f 100644 --- a/conform/Makefile +++ b/conform/Makefile @@ -359,4 +359,3 @@ test-xfail-XOPEN2K/fmtmsg.h/linknamespace = yes test-xfail-XOPEN2K/syslog.h/linknamespace = yes test-xfail-POSIX2008/semaphore.h/linknamespace = yes test-xfail-XOPEN2K8/fmtmsg.h/linknamespace = yes -test-xfail-XOPEN2K8/syslog.h/linknamespace = yes diff --git a/misc/syslog.c b/misc/syslog.c index 3979f42..35cae6c 100644 --- a/misc/syslog.c +++ b/misc/syslog.c @@ -324,7 +324,7 @@ __vsyslog(int pri, const char *fmt, va_list ap) __vsyslog_chk (pri, -1, fmt, ap); } ldbl_hidden_def (__vsyslog, vsyslog) -ldbl_strong_alias (__vsyslog, vsyslog) +ldbl_weak_alias (__vsyslog, vsyslog) static struct sockaddr_un SyslogAddr; /* AF_UNIX address of local logger */