From 543f260c797ba2d628b4440911418d8a77dddf1e Mon Sep 17 00:00:00 2001 From: Timofey Solomko Date: Sun, 15 Jan 2017 14:08:30 +0300 Subject: [PATCH] Disabled reading of zipComment. --- Sources/ZipContainer.swift | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/Sources/ZipContainer.swift b/Sources/ZipContainer.swift index b692a558..396cda3d 100644 --- a/Sources/ZipContainer.swift +++ b/Sources/ZipContainer.swift @@ -75,8 +75,10 @@ public class ZipContainer { zip64RecordExists = true } - let zipComment = String(data: Data(bytes: pointerData.alignedBytes(count: zipCommentLength)), - encoding: .utf8) + // There is also a .ZIP file comment, but we don't need it. + // Here's how it can be processed: + // let zipComment = String(data: Data(bytes: pointerData.alignedBytes(count: zipCommentLength)), + // encoding: .utf8) if zip64RecordExists { // We need to find Zip64 end of CD locator. // Back to start of end of CD record.