Fixed debug code bug, compression seems to work fine, with no loss