zedshaw/lamson — pull request #26 by nburlett (2013-07-22 17:48:34+00:00)
Title: Individually encoded base64 decoded separately

Individually-encoded base64 chunks must be decoded separately
due to padding at the end of base64-encoded chunks. Concatenating
base64 chunks and then decoding them may result in a different string
than decoding and then concatenating.

However, the characterset decoding into unicode must be done jointly,
since some mail clients will split the base64 encoding in the middle
of Unicode characters.

This fixes issue #25 by decoding each chunk separately, concatenating the decoded result, and then running it through the unicode charset decoder.