rdmd fixes 20130310

Fix 3 issues and a bit of cleanup.