From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 11710 invoked by alias); 11 Dec 2017 01:07:06 -0000 Mailing-List: contact zsh-workers-help@zsh.org; run by ezmlm Precedence: bulk X-No-Archive: yes List-Id: Zsh Workers List List-Post: List-Help: List-Unsubscribe: X-Seq: 42106 Received: (qmail 19745 invoked by uid 1010); 11 Dec 2017 01:07:06 -0000 X-Qmail-Scanner-Diagnostics: from out3-smtp.messagingengine.com by f.primenet.com.au (envelope-from , uid 7791) with qmail-scanner-2.11 (clamdscan: 0.99.2/21882. spamassassin: 3.4.1. Clear:RC:0(66.111.4.27):SA:0(-2.6/5.0):. Processed in 2.102771 secs); 11 Dec 2017 01:07:06 -0000 X-Spam-Checker-Version: SpamAssassin 3.4.1 (2015-04-28) on f.primenet.com.au X-Spam-Level: X-Spam-Status: No, score=-2.6 required=5.0 tests=BAYES_00,RCVD_IN_DNSWL_LOW, T_DKIM_INVALID autolearn=ham autolearn_force=no version=3.4.1 X-Envelope-From: d.s@daniel.shahaf.name X-Qmail-Scanner-Mime-Attachments: | X-Qmail-Scanner-Zip-Files: | DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= daniel.shahaf.name; h=content-transfer-encoding:content-type :date:from:in-reply-to:message-id:mime-version:references :subject:to:x-me-sender:x-me-sender:x-sasl-enc; s=fm2; bh=76vMDC Kwfa1xpXdEoHmvKcOo9htp/2okvRNuSQzdPxA=; b=UPBdAPcg9YY1IMnzN4Ylhf jmuy8enRnIwnTwTrxN4ar2PWeR2AxJLzrioDdUEF6FbYUCW9AQRKxh20OKglUCuR F3pEycC6tbVDakvQhlBa5EZvxEocESvp2VOhOdR1DFA7nhVbqhAIDF5/Ub8qiTTA qRVuQfExN6s4iZDWcu8Z/ZvtqVFhjrXvd2//lzRyMhlTdLg5RmjXt+o3lLDrXpaw fhdAhm4IDlIfP/OMGnhh/abT5RdBQg/uNq181v+AzKyIWmum979fYDOtU/kWMa+L ZaNOMi5gMUjiY9qV92rv+HDqMKQEWd4TQglsHsO0HDlVXleETA4zZiOM6BZhk0cw == DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=content-transfer-encoding:content-type :date:from:in-reply-to:message-id:mime-version:references :subject:to:x-me-sender:x-me-sender:x-sasl-enc; s=fm1; bh=76vMDC Kwfa1xpXdEoHmvKcOo9htp/2okvRNuSQzdPxA=; b=EZTxduCEv7SAPvcqhCIQfs VebgezXvmydIBfCa++LkddUjIjD+c80FjS1zGTgnj52ZcVWIXBZ1FIzZkSOz0tdW AqDpIx4GYIiO1BS0Yg7yFm4iJFD4Q73mQ7Q6ozoA68V24CLWyh7y6HfYngeNMSXZ iAvNu6OgwLNlVePCS4aARMDDbY7tDv/6hiFaJHQGiNlwggg2JMX40/eyzc7JU04K EkvpAPhfe/x5tIuqzQqICn/48Z3mOykOQyRbKXt4ssmWO/2dmahlXu3B7IvFpo9w c/q63mLTZ039qG/h4D7ONwiuPzm0lbsWR3vv4ba+CkTmxeCSxV15Ayt8j83IiJYw == X-ME-Sender: Message-Id: <1512954420.1697620.1200536248.20F08CFE@webmail.messagingengine.com> From: Daniel Shahaf To: zsh-workers@zsh.org MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Type: text/plain; charset="utf-8" X-Mailer: MessagingEngine.com Webmail Interface - ajax-c9e5630e In-Reply-To: <86CB677F-70BF-43B2-8F6D-E8F0AC4C43A3@dana.is> Date: Mon, 11 Dec 2017 01:07:00 +0000 Subject: Re: [BUG] Redirect between two parameter assignments causes misbehaviour References: <86CB677F-70BF-43B2-8F6D-E8F0AC4C43A3@dana.is> dana wrote on Sun, 10 Dec 2017 18:19 -0600: > One more before i forget. Someone found this on IRC today and it puzzled us. Thanks for bringing this to the list. > Though it seems that certain interactions with other code can be quite serious. > If i run this without -f, something in my profile causes this series of commands > to hard-lock zsh with 100% CPU. Entering the first command and then the second > one separately avoids this lock-up. Unfortunately `set -x` didn't reveal > anything and i don't have any more time to look at it today, but i thought i'd > mention it. It's spinning in the 'while (1)' in gettext2() on WC_END. If I change the definition of WC_END to 0 then it hits the 'default' branch of the case, returns from gettext2(), and doesn't spin. Without having looked any further into it, I wonder whether we should change WC_END to zero, so if we ever calloc() something and forget to initialise it, it won't be mistaken for valid data.