diff options
author | dkf <donal.k.fellows@manchester.ac.uk> | 2016-09-06 10:46:49 (GMT) |
---|---|---|
committer | dkf <donal.k.fellows@manchester.ac.uk> | 2016-09-06 10:46:49 (GMT) |
commit | 5a3911451c1076781c85ddc9c055b12f7a718f37 (patch) | |
tree | 14bc822772bda53c8ef399cf4d3e66c5c2f09e60 /tests/zlib.test | |
parent | f64a3b8559e5f75f1e208503090cf2503a197470 (diff) | |
parent | 907e3ead5a3a2615c5721af947895bb4cacd3c99 (diff) | |
download | tcl-5a3911451c1076781c85ddc9c055b12f7a718f37.zip tcl-5a3911451c1076781c85ddc9c055b12f7a718f37.tar.gz tcl-5a3911451c1076781c85ddc9c055b12f7a718f37.tar.bz2 |
Fixed bug in pushed transforms with full internal buffers not writing out.
Diffstat (limited to 'tests/zlib.test')
-rw-r--r-- | tests/zlib.test | 23 |
1 files changed, 23 insertions, 0 deletions
diff --git a/tests/zlib.test b/tests/zlib.test index 8a040d8..15dbb34 100644 --- a/tests/zlib.test +++ b/tests/zlib.test @@ -917,6 +917,29 @@ test zlib-12.1 {Tk Bug 9eb55debc5} -constraints zlib -setup { } -cleanup { $stream close } -result {12026 18000} +test zlib-12.2 {Patrick Dunnigan's issue} -constraints zlib -setup { + set filesrc [makeFile {} test.input] + set filedst [makeFile {} test.output] + set f [open $filesrc "wb"] + for {set i 0} {$i < 10000} {incr i} { + puts -nonewline $f "x" + } + close $f +} -body { + set fin [open $filesrc "rb"] + set fout [open $filedst "wb"] + set header [dict create filename "test.input" time 0] + try { + fcopy $fin [zlib push gzip $fout -header $header] + } finally { + close $fin + close $fout + } + file size $filedst +} -cleanup { + removeFile $filesrc + removeFile $filedst +} -result 4152 ::tcltest::cleanupTests return |