mirror of https://github.com/apache/cloudstack.git
Merge pull request #1073 from ustcweizhou/CLOUDSTACK-9055
CLOUDSTACK-9055: fix NPE in updating Redundant State of VPC networksThis issue happened when the KVM nodes is down.It might also happen when the cloudstack-agent is killed unexpectedly. * pr/1073: CLOUDSTACK-9055: fix NPE in updating Redundant State of VPC networks Signed-off-by: Remi Bergsma <github@remi.nl>
This commit is contained in:
commit
238c483a7c
|
|
@ -1013,10 +1013,12 @@ Configurable, StateListener<State, VirtualMachine.Event, VirtualMachine> {
|
|||
s_logger.warn("Unable to update router " + router.getHostName() + "'s status");
|
||||
}
|
||||
RedundantState state = RedundantState.UNKNOWN;
|
||||
if (answer != null && answer.getResult()) {
|
||||
state = answer.getState();
|
||||
} else {
|
||||
s_logger.info("Agent response doesn't seem to be correct ==> " + answer.getResult());
|
||||
if (answer != null) {
|
||||
if (answer.getResult()) {
|
||||
state = answer.getState();
|
||||
} else {
|
||||
s_logger.info("Agent response doesn't seem to be correct ==> " + answer.getResult());
|
||||
}
|
||||
}
|
||||
router.setRedundantState(state);
|
||||
updated = true;
|
||||
|
|
|
|||
Loading…
Reference in New Issue