Index: src/Makefile ================================================================== --- src/Makefile +++ src/Makefile @@ -24,11 +24,10 @@ OFDictionary.m \ OFEnumerator.m \ OFFileManager.m \ OFGZIPStream.m \ OFHMAC.m \ - OFHuffmanTree.m \ OFInflate64Stream.m \ OFInflateStream.m \ OFInvocation.m \ OFLHAArchive.m \ OFLHAArchiveEntry.m \ @@ -181,10 +180,11 @@ OFBitSetCharacterSet.m \ OFBytesValue.m \ OFCRC16.m \ OFCRC32.m \ OFCountedMapTableSet.m \ + OFHuffmanTree.m \ OFInvertedCharacterSet.m \ OFLHADecompressingStream.m \ OFMapTableDictionary.m \ OFMapTableSet.m \ OFMutableAdjacentArray.m \ Index: src/OFInflate64Stream.h ================================================================== --- src/OFInflate64Stream.h +++ src/OFInflate64Stream.h @@ -12,11 +12,10 @@ * LICENSE.GPLv2 or LICENSE.GPLv3 respectively included in the packaging of this * file. */ #import "OFStream.h" -#import "OFHuffmanTree.h" #import "OFKernelEventObserver.h" OF_ASSUME_NONNULL_BEGIN #define OFInflate64StreamBufferSize 4096 @@ -49,23 +48,23 @@ } uncompressedHeader; struct { uint16_t position, length; } uncompressed; struct { - OFHuffmanTree _Nullable litLenTree; - OFHuffmanTree _Nullable distTree; - OFHuffmanTree _Nullable codeLenTree; - OFHuffmanTree _Nullable treeIter; + struct _OFHuffmanTree *_Nullable litLenTree; + struct _OFHuffmanTree *_Nullable distTree; + struct _OFHuffmanTree *_Nullable codeLenTree; + struct _OFHuffmanTree *_Nullable treeIter; uint8_t *_Nullable lengths; uint16_t receivedCount; uint8_t value, litLenCodesCount, distCodesCount; uint8_t codeLenCodesCount; } huffmanTree; struct { - OFHuffmanTree _Nullable litLenTree; - OFHuffmanTree _Nullable distTree; - OFHuffmanTree _Nullable treeIter; + struct _OFHuffmanTree *_Nullable litLenTree; + struct _OFHuffmanTree *_Nullable distTree; + struct _OFHuffmanTree *_Nullable treeIter; int state; uint16_t value, length, distance, extraBits; } huffman; } _context; bool _inLastBlock, _atEndOfStream; Index: src/OFInflateStream.h ================================================================== --- src/OFInflateStream.h +++ src/OFInflateStream.h @@ -12,11 +12,10 @@ * LICENSE.GPLv2 or LICENSE.GPLv3 respectively included in the packaging of this * file. */ #import "OFStream.h" -#import "OFHuffmanTree.h" #import "OFKernelEventObserver.h" OF_ASSUME_NONNULL_BEGIN #define OFInflateStreamBufferSize 4096 @@ -49,23 +48,23 @@ } uncompressedHeader; struct { uint16_t position, length; } uncompressed; struct { - OFHuffmanTree _Nullable litLenTree; - OFHuffmanTree _Nullable distTree; - OFHuffmanTree _Nullable codeLenTree; - OFHuffmanTree _Nullable treeIter; + struct _OFHuffmanTree *_Nullable litLenTree; + struct _OFHuffmanTree *_Nullable distTree; + struct _OFHuffmanTree *_Nullable codeLenTree; + struct _OFHuffmanTree *_Nullable treeIter; uint8_t *_Nullable lengths; uint16_t receivedCount; uint8_t value, litLenCodesCount, distCodesCount; uint8_t codeLenCodesCount; } huffmanTree; struct { - OFHuffmanTree _Nullable litLenTree; - OFHuffmanTree _Nullable distTree; - OFHuffmanTree _Nullable treeIter; + struct _OFHuffmanTree *_Nullable litLenTree; + struct _OFHuffmanTree *_Nullable distTree; + struct _OFHuffmanTree *_Nullable treeIter; int state; uint16_t value, length, distance, extraBits; } huffman; } _context; bool _inLastBlock, _atEndOfStream;