Porting in COGS type fix

Originally from master.

Also imports Istvan's changelog entries that were in the changelog for 1.4 and not in 1.3.