Fixed errors in main.c

Realized that it didn't really work, changed it so it reads in three
bytes into a long, keeping one bit guaranteed free. Then when it had
done enough work to need new bits it grabs another three bytes and adds
it with overflow. Technically it requires complete bytes, but there
isn't any other situation it shouldn't handle. We can set our encoder to
pad with zeroes and make a rule that it doesn't end on an zero,
otherwise we add another byte of zeroes.