unofficial mirror of guile-devel@gnu.org 
 help / color / mirror / Atom feed
From: Mark H Weaver <mhw@netris.org>
To: Nala Ginrut <nalaginrut@gmail.com>
Cc: guile-devel@gnu.org
Subject: Re: [PATCH] Fix get-bytevector-all read redundant eof
Date: Fri, 15 Mar 2013 17:20:47 -0400	[thread overview]
Message-ID: <87k3p8z7f4.fsf@tines.lan> (raw)
In-Reply-To: <1363336772.3025.26.camel@Renee-desktop.suse> (Nala Ginrut's message of "Fri, 15 Mar 2013 16:39:32 +0800")

Nala Ginrut <nalaginrut@gmail.com> writes:

> On Thu, 2013-03-14 at 17:30 +0800, Nala Ginrut wrote:
>> Attached the patch to fix get-bytevector-all.
>> You may check it like this:
>> (get-bytevector-all (current-input-port))
>> 
>> And try to input then type ctrl+d, the current implementation needs you
>> type ctrl+d twice.
>> 
>> Regards.
>
>
> Sorry, but I realized that this patch only fixed when you type ctrl+d in
> the beginning. But if you input something, the problem is still there.
> I'll look deeper.

FWIW, I suspect you'll have to dig fairly deep to fix this properly.
AFAIK, the ports code was not designed to ensure that exactly one EOF is
reported to the user for each EOF returned by the kernel.  I hope to
look into this soon (possibly before 2.0.8), as part of my investigation
of <http://bugs.gnu.org/12216>.

    Thanks,
      Mark



  reply	other threads:[~2013-03-15 21:20 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-03-14  9:30 [PATCH] Fix get-bytevector-all read redundant eof Nala Ginrut
2013-03-15  8:39 ` Nala Ginrut
2013-03-15 21:20   ` Mark H Weaver [this message]
2013-03-16  4:25     ` Nala Ginrut
2013-04-01  1:18 ` Mark H Weaver

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=87k3p8z7f4.fsf@tines.lan \
    --to=mhw@netris.org \
    --cc=guile-devel@gnu.org \
    --cc=nalaginrut@gmail.com \
    /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).