From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 18661 invoked by alias); 5 May 2013 06:52:36 -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: X-Seq: 31372 Received: (qmail 5913 invoked from network); 5 May 2013 06:52:31 -0000 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on f.primenet.com.au X-Spam-Level: X-Spam-Status: No, score=-2.6 required=5.0 tests=BAYES_00,HTML_MESSAGE, RCVD_IN_DNSWL_LOW autolearn=ham version=3.3.2 Received-SPF: none (ns1.primenet.com.au: domain at brasslantern.com does not designate permitted sender hosts) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=mime-version:x-received:in-reply-to:references:date:message-id :subject:from:to:content-type:x-gm-message-state; bh=IA9lGdEv/ad7TqWUqs62tMp1n64ayDDu26S9fm7Ifqc=; b=YtnrhAxegu6lQDY+3jzZg0hXkj2YkgevL+OO7jqo9RbWCMiRlOCFa5sFXTJWlKxEA3 aK1n0xyscT3J5+KxZYLxSBH4fBoE2fP8Fmb64MgNGZx469GwFFSxAdb5Kl0ARgVEI3SA UqYFNHj8GUNZYUF+e6CrRYOQcOuN4vxO8HO1FW1r8Svkg7YO/gNtvnRms6zarN2IOR+s D89SQ9mO1qL9QGTLFAKIwzFnE5zt9NjLhMc9pyZRm8/2Re7IFSSjJ0Wbh8b+XCZWE/e2 sHoVUPwYp2DIQnZdmuyhRAupPoIlAzNN97uaO8n7NQpdzNeG6BAWl2HJ5JbWJHauy5JT 1yrg== MIME-Version: 1.0 X-Received: by 10.112.134.70 with SMTP id pi6mr6296658lbb.72.1367736740591; Sat, 04 May 2013 23:52:20 -0700 (PDT) In-Reply-To: <8738u2b8gy.fsf@ft.bewatermyfriend.org> References: <130425111646.ZM17258@torch.brasslantern.com> <130426080805.ZM18619@torch.brasslantern.com> <517C0E09.4040505@users.sourceforge.net> <130427153141.ZM20125@torch.brasslantern.com> <517D40B0.8020609@thregr.org> <130428180338.ZM14577@torch.brasslantern.com> <8738u2b8gy.fsf@ft.bewatermyfriend.org> Date: Sat, 4 May 2013 23:52:20 -0700 Message-ID: Subject: Re: precmd: write error: interrupted From: Bart Schaefer To: Zsh hackers list Content-Type: multipart/alternative; boundary=047d7b3a8ac091c74604dbf3063f X-Gm-Message-State: ALoCoQkWU3dL4dXIv91kdn3UnWyeIjWMqZGJzeWJo22vaKqGG63fqWfG/flJAfKM485wczUhrCzR --047d7b3a8ac091c74604dbf3063f Content-Type: text/plain; charset=ISO-8859-1 On Sat, May 4, 2013 at 5:01 PM, Frank Terbeck wrote: > Hi Bart, > > I'm afraid these changes break SIGWINCH handling of child processes. > > Not entirely surprising. I wondered about that but tried it with a couple of apps before posting and they seemed to be responding to the change in size. I didn't actually test whether they were receiving WINCH, though. The below should help, but someone will have to commit it for me, because the computer with my sourceforge ssh keys suffered a video chip meltdown yesterday and I haven't had a chance to repair it or pull the key file from backup yet. For the same reason, I'm composing this in gmail, so I hope the patch has not been mangled. Something similar may also be needed in the zpty and clone modules. (Has anyone ever used the clone module for anything?) diff --git a/Src/exec.c b/Src/exec.c index fa14875..c71f3f3 100644 --- a/Src/exec.c +++ b/Src/exec.c @@ -303,11 +303,13 @@ zfork(struct timeval *tv) zerr("fork failed: %e", errno); return -1; } + if (!pid) { + winch_unblock(); #ifdef HAVE_GETRLIMIT - if (!pid) /* set resource limits for the child process */ setlimits(NULL); #endif + } return pid; } --047d7b3a8ac091c74604dbf3063f--