From 0cd75fb1770c47c75be4d4c680922fc9416b3d5a Mon Sep 17 00:00:00 2001 From: Joe Groff Date: Mon, 25 Jan 2010 20:27:07 -0800 Subject: [PATCH] don't leak the Factor stream when the vorbis-stream finishes --- extra/audio/vorbis/vorbis.factor | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/extra/audio/vorbis/vorbis.factor b/extra/audio/vorbis/vorbis.factor index 7fce2b4316..78f637770f 100644 --- a/extra/audio/vorbis/vorbis.factor +++ b/extra/audio/vorbis/vorbis.factor @@ -233,7 +233,7 @@ PRIVATE> ] with-destructors ; : read-vorbis-stream ( filename buffer-size -- vorbis-stream ) - [ binary ] dip ; inline + [ [ binary |dispose ] dip ] with-destructors ; inline M: vorbis-stream dispose* { @@ -246,6 +246,7 @@ M: vorbis-stream dispose* [ page>> [ free ] when* ] [ sync-state>> [ free ] when* ] [ packet>> [ free ] when* ] + [ stream>> [ dispose ] when* ] } cleave ; M: vorbis-stream generator-audio-format