From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.org/gmane.linux.lib.musl.general/11132 Path: news.gmane.org!.POSTED!not-for-mail From: Rich Felker Newsgroups: gmane.linux.lib.musl.general Subject: Re: [PATCH] emulate lazy binding Date: Tue, 14 Mar 2017 14:14:09 -0400 Message-ID: <20170314181409.GA1693@brightrain.aerifal.cx> References: <20170313234735.GE1520@brightrain.aerifal.cx> Reply-To: musl@lists.openwall.com NNTP-Posting-Host: blaine.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: blaine.gmane.org 1489515263 28874 195.159.176.226 (14 Mar 2017 18:14:23 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Tue, 14 Mar 2017 18:14:23 +0000 (UTC) User-Agent: Mutt/1.5.21 (2010-09-15) To: musl@lists.openwall.com Original-X-From: musl-return-11147-gllmg-musl=m.gmane.org@lists.openwall.com Tue Mar 14 19:14:19 2017 Return-path: Envelope-to: gllmg-musl@m.gmane.org Original-Received: from mother.openwall.net ([195.42.179.200]) by blaine.gmane.org with smtp (Exim 4.84_2) (envelope-from ) id 1cnqxf-00076p-Ap for gllmg-musl@m.gmane.org; Tue, 14 Mar 2017 19:14:19 +0100 Original-Received: (qmail 22299 invoked by uid 550); 14 Mar 2017 18:14:22 -0000 Mailing-List: contact musl-help@lists.openwall.com; run by ezmlm Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-ID: Original-Received: (qmail 22277 invoked from network); 14 Mar 2017 18:14:21 -0000 Content-Disposition: inline In-Reply-To: <20170313234735.GE1520@brightrain.aerifal.cx> Original-Sender: Rich Felker Xref: news.gmane.org gmane.linux.lib.musl.general:11132 Archived-At: On Mon, Mar 13, 2017 at 07:47:35PM -0400, Rich Felker wrote: > > +static void prepare_lazy(struct dso *p) > +{ > + size_t dyn[DYN_CNT], n, flags1; > + decode_vec(p->dynv, dyn, DYN_CNT); > + search_vec(p->dynv, &flags1, DT_FLAGS_1); > + if (dyn[DT_BIND_NOW] || (dyn[DT_FLAGS] & DF_BIND_NOW) || (flags1 & DF_1_NOW)) > + return; One fix, flags1 should be initialized to 0 in case search_vec fails. I'll go ahead and commit soon. Rich