Gitweb: http://git.fedorahosted.org/git/fence-agents.git?p=fence-agents.git;a=commit... Commit: f31f957471dea5d955758db98226a727405248d7 Parent: 1ef8f0605ef021a7f0045d9be19497ef95a2a16e Author: Marek 'marx' Grac mgrac@redhat.com AuthorDate: Mon Apr 4 15:11:59 2011 +0200 Committer: Marek 'marx' Grac mgrac@redhat.com CommitterDate: Mon Apr 4 15:11:59 2011 +0200
fence_ipmilan: returns incorrect status on monitor op if chassis is powered off
There is a bug in fence_ipmilan agent: it exits with result code 2 on "monitor"/"status" command if chassis is powered off. Instead it should return 0 because "monitor" command should return fence device status, not chassis status.
Reported and patch proposed by Vladislav Bogdanov
Resolves: rhbz#690735 --- fence/agents/ipmilan/ipmilan.c | 4 ++++ 1 files changed, 4 insertions(+), 0 deletions(-)
diff --git a/fence/agents/ipmilan/ipmilan.c b/fence/agents/ipmilan/ipmilan.c index d34ced5..040babf 100644 --- a/fence/agents/ipmilan/ipmilan.c +++ b/fence/agents/ipmilan/ipmilan.c @@ -1192,5 +1192,9 @@ metaout: else printf("Failed\n"); } + + if (!strcasecmp(op, "monitor")) + translated_ret = ret; + return translated_ret; }