[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: GSFileHandle doesn't work on Serial Ports
From: |
Richard Frith-Macdonald |
Subject: |
Re: GSFileHandle doesn't work on Serial Ports |
Date: |
Wed, 8 Feb 2006 08:18:26 +0000 |
On 3 Feb 2006, at 15:14, Marc Brünink wrote:
Hi,
in [GSFileHandle read:length:] we use a read() system call. If I
understood it correctly read() blocks until the requested amount of
data is read or special circumstances raise (e.g. EOF). On a steady
serial connection there's no such thing as EOT. Therefore
[NSFileHandle availableData], [NSFileHandle
readInBackgroundAndNotify],... block until READ_SIZE bytes are
read. I've seen this on Windows XP, Solaris 10 and I belief on
debain sarge, too.
I've comitted a change to subversion which should fix this ... the
code was just setting the handle to be blocking when it should have
set it to non-blocking.