cmd_repair fix to be backward compatible

I got a lot messages when upgraded to cfengine 3.6 that promise was fail...ed, due the fact
that return code '0' is not seen has promise kept. That is why i added kept_returncode
statement to be backwards compatible