unofficial mirror of guile-devel@gnu.org 
 help / color / mirror / Atom feed
From: ludo@gnu.org (Ludovic Courtès)
To: guile-devel@gnu.org
Subject: SCM_SYSCALL
Date: Sun, 23 Jun 2013 23:25:10 +0200	[thread overview]
Message-ID: <87li607c5l.fsf@gnu.org> (raw)

Hello Guilers!

We have this (since 2010):

--8<---------------cut here---------------start------------->8---
#   define SCM_SYSCALL(line)                    \
  do                                            \
    {                                           \
      errno = 0;                                \
      line;                                     \
      if (errno == EINTR)                       \
        {                                       \
          SCM_ASYNC_TICK;                       \
          continue;                             \
        }                                       \
    }                                           \
  while(0)
--8<---------------cut here---------------end--------------->8---

It turns out that the effect upon EINTR is to leave the loop.  So
typically, fport_fill_input just throws to system-error and reveals the
EINTR, contrary to SCM_SYSCALL intends to do.

This is easily fixed, but the question is whether this would affect
users in bad ways.  For example, applications might be relying on the
ability to do

  (catch 'system-error
    ...
    (lambda args
      (if (= EINTR (system-error-errno args))
          ...)))

Should the fix be delayed until 2.2?
WDYT?

Ludo’.




             reply	other threads:[~2013-06-23 21:25 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-06-23 21:25 Ludovic Courtès [this message]
2013-07-03 18:19 ` SCM_SYSCALL Mark H Weaver
2013-07-04 22:28   ` SCM_SYSCALL Ludovic Courtès
2013-07-05 18:56     ` SCM_SYSCALL Mark H Weaver
2013-07-05 20:01       ` SCM_SYSCALL Ludovic Courtès
2013-07-06 16:41         ` SCM_SYSCALL Mark H Weaver
2013-07-06 21:05           ` SCM_SYSCALL Ludovic Courtès
2013-07-17 16:04 ` SCM_SYSCALL Ludovic Courtès
2014-03-23 19:56 ` SCM_SYSCALL Andy Wingo

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

  List information: https://www.gnu.org/software/guile/

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

  git send-email \
    --in-reply-to=87li607c5l.fsf@gnu.org \
    --to=ludo@gnu.org \
    --cc=guile-devel@gnu.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.
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 read-only IMAP folder(s) and NNTP newsgroup(s).