Fixes to my fix suggested by Edi Weitz