diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/openvz/openvz_driver.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/openvz/openvz_driver.c b/src/openvz/openvz_driver.c index 8257ed560..a1d3b42b4 100644 --- a/src/openvz/openvz_driver.c +++ b/src/openvz/openvz_driver.c @@ -1707,7 +1707,7 @@ openvzDomainGetBarrierLimit(virDomainPtr domain, virCommandSetOutputBuffer(cmd, &output); virCommandAddArgFormat(cmd, "-o%s.b,%s.l", param, param); virCommandAddArg(cmd, domain->name); - if (virCommandRun(cmd, &status)) { + if (virCommandRun(cmd, &status) < 0 || status != 0) { virReportError(VIR_ERR_OPERATION_FAILED, _("Failed to get %s for %s: %d"), param, domain->name, status); @@ -1758,7 +1758,7 @@ openvzDomainSetBarrierLimit(virDomainPtr domain, virCommandAddArgFormat(cmd, "--%s", param); virCommandAddArgFormat(cmd, "%llu:%llu", barrier, limit); virCommandAddArg(cmd, "--save"); - if (virCommandRun(cmd, &status)) { + if (virCommandRun(cmd, &status) < 0 || status != 0) { virReportError(VIR_ERR_OPERATION_FAILED, _("Failed to set %s for %s: %d"), param, domain->name, status); |