file/tar: limit pipe size between tar and gzip

Otherwise, tar is likely to get ahead of gzip and use much
more memory.
This commit is contained in:
Matthew Flatt 2013-07-25 10:11:05 -06:00
parent 949ea16cbf
commit a5d724dda4

View File

@ -155,7 +155,7 @@
(when (null? paths) (error 'tar-gzip "no paths specified"))
(with-output-to-file tgz-file
(lambda ()
(let-values ([(i o) (make-pipe)])
(let-values ([(i o) (make-pipe (* 1024 1024 32))])
(thread (lambda ()
(tar->output (pathlist-closure paths #:follow-links? #f) o
#:path-prefix prefix)