io.pipes: If dispose on in>> throws, then out>> leaks.

db4
Doug Coleman 2013-05-19 10:12:38 -07:00
parent 917ae3e410
commit c64cb2c886
1 changed files with 4 additions and 1 deletions

View File

@ -9,7 +9,10 @@ IN: io.pipes
TUPLE: pipe in out ;
M: pipe dispose ( pipe -- )
[ in>> dispose ] [ out>> dispose ] bi ;
[
[ in>> &dispose drop ]
[ out>> &dispose drop ] bi
] with-destructors ;
HOOK: (pipe) io-backend ( -- pipe )