Some more bug fixes. (v3.6.2)