zsh-workers
 help / color / mirror / code / Atom feed
From: Bart Schaefer <schaefer@brasslantern.com>
To: Peter Stephenson <p.stephenson@samsung.com>
Cc: Zsh hackers list <zsh-workers@zsh.org>
Subject: Re: TR : Re : [BUG] Crash due to malloc call in signal handler
Date: Fri, 13 Dec 2019 13:10:07 -0800	[thread overview]
Message-ID: <CAH+w=7YkBVd7owgYo518hwOz1Kq9ZUxvLYgk_V1ZJ_sd5pVOOw@mail.gmail.com> (raw)
In-Reply-To: <1576258224.5214.31.camel@samsung.com>

[-- Attachment #1: Type: text/plain, Size: 442 bytes --]

On Fri, Dec 13, 2019, 9:31 AM Peter Stephenson <p.stephenson@samsung.com>
wrote:

>
> If you're using the current git source, exec.c line 4673 has a call to
> fgetc(), which is indeed outside where signals are queued. ... The fix
> might be
> not to fdopen() the input file, but just read into a buffer with
> read().
>

Yeah, calling stdio routines with signals unblocked is not safe.  We should
be doing explicit memory management here.

>

      parent reply	other threads:[~2019-12-13 21:11 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <CGME20191213171028eucas1p2e7820377701008b2d05c898192b7c17e@eucas1p2.samsung.com>
2019-12-13 17:09 ` Antoine C.
2019-12-13 17:30   ` Peter Stephenson
2019-12-13 21:08     ` Peter Stephenson
2019-12-14 12:32       ` Peter Stephenson
2019-12-15 19:06         ` Peter Stephenson
2019-12-16  4:00           ` Daniel Shahaf
2019-12-16 10:05             ` Peter Stephenson
2019-12-13 21:10     ` Bart Schaefer [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to='CAH+w=7YkBVd7owgYo518hwOz1Kq9ZUxvLYgk_V1ZJ_sd5pVOOw@mail.gmail.com' \
    --to=schaefer@brasslantern.com \
    --cc=p.stephenson@samsung.com \
    --cc=zsh-workers@zsh.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.vuxu.org/mirror/zsh/

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).