Fixes by Michael Doser