[Larceny-users] Synch To Latest Larceny SVN Updates - Success

Jed Davis jld at ccs.neu.edu
Mon Jul 28 02:45:37 EDT 2008


On Sun, Jul 27, 2008 at 10:18:58PM -0400, Ray Racine wrote:
>
> However, I'm wondering since the SIGPIPE signal is happening in the
> socket code and given that the EPIPE error number is returned and
> therefore available, it might be better in the long run to continue to
> ignore the SIGPIPE and handle the EPIPE directly by cleaning up the
> socket fd inside the socket port read/write code.

Somewhere I have a half-written message from the last time this came up,
opining that there's not much point to SIGPIPE if you're checking the
return from write() and friends.

That is, my understanding of SIGPIPE is that it's at best a convenience
feature for pipeline filters (or one-shot network things) written in C
(or other language without some sort of exception mechanism), where you
always want to exit when the pipe/socket goes away.

(Also, SIG_IGN is not quite the same thing as an empty signal handler
function, but the difference is not observable here.)

-- 
(let ((C call-with-current-continuation)) (apply (lambda (x y) (x y)) (map
((lambda (r) ((C C) (lambda (s) (r (lambda l (apply (s s) l))))))  (lambda
(f) (lambda (l) (if (null? l) C (lambda (k) (display (car l)) ((f (cdr l))
(C k)))))))    '((#\J #\d #\D #\v #\s) (#\e #\space #\a #\i #\newline)))))



More information about the Larceny-users mailing list