This is the mail archive of the guile@sourceware.cygnus.com mailing list for the Guile project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: Two unexpected test failures.


> Date: Thu, 30 Mar 2000 10:41:25 +0200 (MEST)
> From: Dirk Herrmann <dirk@ida.ing.tu-bs.de>

> > What happens if you run these on Solaris?
> > 
> > (let* ((p (pipe))
> >        (r (car p)))
> >   (fcntl r F_SETFL O_NONBLOCK)
> >   (read-char r))
> 
> Backtrace:
> 0* (let* ((p (pipe)) (r (car p))) (fcntl r F_SETFL O_NONBLOCK) (read-char r))
> 1  [read-char #<input: read pipe 5>]
> 
> ERROR: In procedure read-char in expression (read-char r):
> ERROR: Resource temporarily unavailable
> ABORT: (system-error)

Thanks, that's what it's supposed to do.  Most likely the test script
needs to check for EWOULDBLOCK as well as EAGAIN.  Here's another test
to confirm it:

(let* ((p (pipe))
       (r (car p)))
  (fcntl r F_SETFL O_NONBLOCK)
  (catch 'system-error
    (lambda () (read-char r))
    (lambda (key . args)
      (write key)
      (newline)
      (write args)
      (newline)
      (write EAGAIN)
      (newline)
      (write EWOULDBLOCK)
      (newline))))

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]