{"id":808862,"url":"http://patchwork.ozlabs.org/api/1.0/patches/808862/?format=json","project":{"id":41,"url":"http://patchwork.ozlabs.org/api/1.0/projects/41/?format=json","name":"GNU C Library","link_name":"glibc","list_id":"libc-alpha.sourceware.org","list_email":"libc-alpha@sourceware.org","web_url":"","scm_url":"","webscm_url":""},"msgid":"<20170901180029.9527-54-hjl.tools@gmail.com>","date":"2017-09-01T18:00:24","name":"[53/58] Hide internal __moncontrol function [BZ #18822]","commit_ref":null,"pull_url":null,"state":"new","archived":false,"hash":"d43b62e631de031c94a2b5ec0113b0d6d70c46cf","submitter":{"id":4387,"url":"http://patchwork.ozlabs.org/api/1.0/people/4387/?format=json","name":"H.J. Lu","email":"hjl.tools@gmail.com"},"delegate":null,"mbox":"http://patchwork.ozlabs.org/project/glibc/patch/20170901180029.9527-54-hjl.tools@gmail.com/mbox/","series":[{"id":1088,"url":"http://patchwork.ozlabs.org/api/1.0/series/1088/?format=json","date":"2017-09-01T18:00:21","name":"Hide internal functions in libc.so","version":1,"mbox":"http://patchwork.ozlabs.org/series/1088/mbox/"}],"check":"pending","checks":"http://patchwork.ozlabs.org/api/patches/808862/checks/","tags":{},"headers":{"Return-Path":"<libc-alpha-return-84059-incoming=patchwork.ozlabs.org@sourceware.org>","X-Original-To":"incoming@patchwork.ozlabs.org","Delivered-To":["patchwork-incoming@bilbo.ozlabs.org","mailing list libc-alpha@sourceware.org"],"Authentication-Results":["ozlabs.org;\n\tspf=pass (mailfrom) smtp.mailfrom=sourceware.org\n\t(client-ip=209.132.180.131; helo=sourceware.org;\n\tenvelope-from=libc-alpha-return-84059-incoming=patchwork.ozlabs.org@sourceware.org;\n\treceiver=<UNKNOWN>)","ozlabs.org; dkim=pass (1024-bit key;\n\tsecure) header.d=sourceware.org header.i=@sourceware.org\n\theader.b=\"NrAm4EA5\"; dkim-atps=neutral","sourceware.org; auth=none"],"Received":["from sourceware.org (server1.sourceware.org [209.132.180.131])\n\t(using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256\n\tbits)) (No client certificate requested)\n\tby ozlabs.org (Postfix) with ESMTPS id 3xkRty1dG6z9s7M\n\tfor <incoming@patchwork.ozlabs.org>;\n\tSat,  2 Sep 2017 04:03:38 +1000 (AEST)","(qmail 85117 invoked by alias); 1 Sep 2017 18:00:51 -0000","(qmail 85059 invoked by uid 89); 1 Sep 2017 18:00:50 -0000"],"DomainKey-Signature":"a=rsa-sha1; c=nofws; d=sourceware.org; h=list-id\n\t:list-unsubscribe:list-subscribe:list-archive:list-post\n\t:list-help:sender:from:to:subject:date:message-id:in-reply-to\n\t:references; q=dns; s=default; b=kmPwUYHwsPHlxfuR6v4Ucb4fM/T3O5s\n\t4gX5Zp6XrSj30nbYiZUF1K/oFYQVx09WOeFHOCS0O6/F4Z27icc2YrrOvINNyOnR\n\t+vDasVP1pvtOu6T8enIiPASAgikHNozwYYmayK4RAgTslots8Dswyn2q97NxR6Sk\n\tMLbeVNa1Tyug=","DKIM-Signature":"v=1; a=rsa-sha1; c=relaxed; d=sourceware.org; h=list-id\n\t:list-unsubscribe:list-subscribe:list-archive:list-post\n\t:list-help:sender:from:to:subject:date:message-id:in-reply-to\n\t:references; s=default; bh=sARXF9CgGH1QKw9yD6u6+2mTkV4=; b=NrAm4\n\tEA5dPsHFGD/89qj3ZBtLZZNWKttgXaijCsZT8vJBfZmLK7MlWwx2Zt/J/8pKpVH8\n\tznJg7HXTmd9yCnhPdIRcQb6XRyENxh+BBQUkCszfj3sAKGiZWNS6thpBGqsdzWZB\n\trUjNBo78lCtYfXgBOiaM58cy2UrNgWm+/JSOLU=","Mailing-List":"contact libc-alpha-help@sourceware.org; run by ezmlm","Precedence":"bulk","List-Id":"<libc-alpha.sourceware.org>","List-Unsubscribe":"<mailto:libc-alpha-unsubscribe-incoming=patchwork.ozlabs.org@sourceware.org>","List-Subscribe":"<mailto:libc-alpha-subscribe@sourceware.org>","List-Archive":"<http://sourceware.org/ml/libc-alpha/>","List-Post":"<mailto:libc-alpha@sourceware.org>","List-Help":"<mailto:libc-alpha-help@sourceware.org>,\n\t<http://sourceware.org/ml/#faqs>","Sender":"libc-alpha-owner@sourceware.org","X-Virus-Found":"No","X-Spam-SWARE-Status":"No, score=-26.2 required=5.0 tests=BAYES_00,\n\tFREEMAIL_FROM, GIT_PATCH_0, GIT_PATCH_1, GIT_PATCH_2,\n\tGIT_PATCH_3,\n\tSPF_SOFTFAIL autolearn=ham version=3.3.2 spammy=H*m:gmail","X-HELO":"mga06.intel.com","X-ExtLoop1":"1","From":"\"H.J. Lu\" <hjl.tools@gmail.com>","To":"libc-alpha@sourceware.org","Subject":"[PATCH 53/58] Hide internal __moncontrol function [BZ #18822]","Date":"Fri,  1 Sep 2017 11:00:24 -0700","Message-Id":"<20170901180029.9527-54-hjl.tools@gmail.com>","In-Reply-To":"<20170901180029.9527-1-hjl.tools@gmail.com>","References":"<20170901180029.9527-1-hjl.tools@gmail.com>"},"content":"Hide internal __moncontrol function to allow direct access within libc.so\nand libc.a without using GOT nor PLT.\n\n\t[BZ #18822]\n\t* mon/gmon.c (__moncontrol): Add libc_hidden_proto and\n\tlibc_hidden_def.\n---\n gmon/gmon.c | 2 ++\n 1 file changed, 2 insertions(+)","diff":"diff --git a/gmon/gmon.c b/gmon/gmon.c\nindex 4e48eba1bf..f1aa3b776c 100644\n--- a/gmon/gmon.c\n+++ b/gmon/gmon.c\n@@ -62,6 +62,7 @@ static int\ts_scale;\n \n void moncontrol (int mode);\n void __moncontrol (int mode);\n+libc_hidden_proto (__moncontrol)\n static void write_hist (int fd);\n static void write_call_graph (int fd);\n static void write_bb_counts (int fd);\n@@ -93,6 +94,7 @@ __moncontrol (int mode)\n       p->state = GMON_PROF_OFF;\n     }\n }\n+libc_hidden_def (__moncontrol)\n weak_alias (__moncontrol, moncontrol)\n \n \n","prefixes":["53/58"]}