summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/zip.cr2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/zip.cr b/src/zip.cr
index dff3014..6660fc8 100644
--- a/src/zip.cr
+++ b/src/zip.cr
@@ -446,7 +446,7 @@ module Zip
def to_s(io) : UInt16
@code.to_u16.to_io(io, LE)
@data.size.to_u16.to_io(io, LE)
- @data.to_s(io)
+ @data.to_s(io) if @data.size > 0
# return number of bytes written
bytes_needed