1.16.5 release

Several minor bugfixes.