fix 1st round of issues reported by haarg@cpan.org