Fix a couple of error paths so they set errno.
Fix a couple of error paths so they set errno.

stevenraspudic/resource-agents,asp24/resource-agents,stevenraspudic/resource-agents,asp24/resource-agents,asp24/resource-agents,stevenraspudic/resource-agents