Import all of the changes from master onto the new jsmime version.

--HG--
extra : rebase_source : 4c2ae1e08db71fc014528df9f15ed4ea3f82b6a9
extra : amend_source : 3f78151f1a15fe286a773c6b3a33a5ba4fcdf380