Huffman encoder/compressor in C