Fix #1, RT#99186 and incompat with perl 5.21.4