added a function to read in the huffman message properly