rmpkg: fix exit code