Hg: Merge in some more crm-stable changes
Mercurial revision: 0431e7c0e67411b9c28412c4189d59121c3ea3c3