Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Re: Race condition when setting TERM{,INFO{,_DIRS}}
- X-seq: zsh-workers 41380
- From: Mikael Magnusson <mikachu@xxxxxxxxx>
- To: "Guillaume Maudoux (Layus)" <layus.on@xxxxxxxxx>
- Subject: Re: Race condition when setting TERM{,INFO{,_DIRS}}
- Date: Fri, 30 Jun 2017 14:34:46 +0200
- Cc: Bart Schaefer <schaefer@xxxxxxxxxxxxxxxx>, zsh workers <zsh-workers@xxxxxxx>
- Dkim-signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc; bh=K1BLy98hTkYRP/04PJPcdvJPnbBuWsWB8jkKpdsAWkI=; b=GXzNI0zX8zP1nNPnfRy+zUvcdVrEYpdirolen+jKcqsHW7ulYnWxb2Lc4IG0qrDYsy 8ETnash5b24+MWfipSsbCyHTvF7gD8mS+WJu7o/VEoG2saRYE6HdAieP48cxabeApIBJ 5f2Q+/fqQUvTh68WWt/JWmvfLUCO3u79sull0NtrWysc1aBJfr2UczdKS7xkD0P2+32o GHhKu5Hffxx/tNLG73Q8plXEBsiw3ovUEX6o7LdP4BCJcHJafsELJmGHjlro1QH4RfXX L1ggukpjWJwoGg70/U/q59DBSSHBrwI2czgWC1ebc4GPpLkWPk22+e7X4oPhkAJMZw9E KTEw==
- In-reply-to: <45762363-3882-27b8-8433-63ccfdc0b8be@gmail.com>
- List-help: <mailto:zsh-workers-help@zsh.org>
- List-id: Zsh Workers List <zsh-workers.zsh.org>
- List-post: <mailto:zsh-workers@zsh.org>
- Mailing-list: contact zsh-workers-help@xxxxxxx; run by ezmlm
- References: <2ad57c3b-f0c4-afd9-4789-ae50571c63e1@gmail.com> <170627143044.ZM8536@torch.brasslantern.com> <45762363-3882-27b8-8433-63ccfdc0b8be@gmail.com>
On Fri, Jun 30, 2017 at 1:49 PM, Guillaume Maudoux (Layus)
<layus.on@xxxxxxxxx> wrote:
> Thanks Bart,
>
> I have found the origin of this issue.
> There are no threads indeed, but there is caching in ncurses for environment
> variables.
>
> Due to a bug in ncurses' code, it failed to detect that the environment var
> changed,
> and so failed to find the terminfo database.
>
> I will send a patch upstream, with this list in cc.
>
> Zsh could avoid that by initializing the term as late as possible.
> Calling init_term before parsing zshrc, while nothing required to write in
> the terminal is premature.
> Fish for example delays initializing the terminal until the first write.
> Well, this would have avoided my issue, but it is not sufficient in the
> general case anyway.
Plenty of people (including me) write to the terminal from zshrc and
other initialization files.
--
Mikael Magnusson
Messages sorted by:
Reverse Date,
Date,
Thread,
Author