Plugin.pm: enhance $statefile error handling