From f759e35cd8399d8bffea4d59c5822db8f1002409 Mon Sep 17 00:00:00 2001 From: Steven Fuller Date: Sat, 28 Jul 2001 04:44:27 +0000 Subject: More compilation. Moved windows typedefs to a separate file. Included public domain md5 routines (from dpkg). --- src/win95/huffman.cpp | 32 +++++++++++++++++--------------- 1 file changed, 17 insertions(+), 15 deletions(-) (limited to 'src/win95/huffman.cpp') diff --git a/src/win95/huffman.cpp b/src/win95/huffman.cpp index b2a0275..64100e1 100644 --- a/src/win95/huffman.cpp +++ b/src/win95/huffman.cpp @@ -1,7 +1,9 @@ -#include "stdio.h" -#include "stdlib.h" -#include "string.h" -#include "malloc.h" +#include +#include +#include + +#include "fixer.h" + #include "huffman.hpp" /* KJL 17:12:25 17/09/98 - Huffman compression/decompression routines */ @@ -28,17 +30,17 @@ typedef struct HuffNode // 16-byte node structure struct HuffNode *parent; // the THIRD four bytes, parent node - union - { // the FOURTH four bytes +// union +// { // the FOURTH four bytes unsigned int bits; // the bit pattern of this end node - struct - { - unsigned char flag; - unsigned char curdepth; - unsigned char maxdepth; - unsigned char unused; - }; - }; +// struct +// { +// unsigned char flag; +// unsigned char curdepth; +// unsigned char maxdepth; +// unsigned char unused; +// }; +// }; } HuffNode; @@ -99,7 +101,7 @@ extern HuffmanPackage *HuffmanCompression(unsigned char *sourcePtr, int length) { outpackage->CodelengthCount[n] = Depths[n + 1]; } - for (n = 0; n < 256; n++) + for (int n = 0; n < 256; n++) { outpackage->ByteAssignment[n] = SymbolCensus[n + 1].Symbol; } -- cgit v1.3