Signed-off-by: Daniel Henrique Barboza <danielhb413(a)gmail.com>
---
src/lxc/lxc_container.c | 7 ++-----
src/lxc/lxc_controller.c | 10 ++++------
2 files changed, 6 insertions(+), 11 deletions(-)
diff --git a/src/lxc/lxc_container.c b/src/lxc/lxc_container.c
index 42ed08ede6..b44cc68e67 100644
--- a/src/lxc/lxc_container.c
+++ b/src/lxc/lxc_container.c
@@ -380,18 +380,15 @@ static int lxcContainerSetupFDs(int *ttyfd,
*/
int lxcContainerSendContinue(int control)
{
- int rc = -1;
lxc_message_t msg = LXC_CONTINUE_MSG;
int writeCount = 0;
VIR_DEBUG("Send continue on fd %d", control);
writeCount = safewrite(control, &msg, sizeof(msg));
if (writeCount != sizeof(msg))
- goto error_out;
+ return -1;
- rc = 0;
- error_out:
- return rc;
+ return 0;
}
/**
diff --git a/src/lxc/lxc_controller.c b/src/lxc/lxc_controller.c
index e572c3f5fd..42c631ed0b 100644
--- a/src/lxc/lxc_controller.c
+++ b/src/lxc/lxc_controller.c
@@ -1115,7 +1115,7 @@ static void
virLXCControllerConsoleUpdateWatch(virLXCControllerConsolePtr consol
virReportSystemError(errno, "%s",
_("Unable to add epoll fd"));
virNetDaemonQuit(console->daemon);
- goto cleanup;
+ return;
}
console->hostEpoll = events;
VIR_DEBUG("newHostEvents=%x oldHostEvents=%x", events,
console->hostEpoll);
@@ -1127,7 +1127,7 @@ static void
virLXCControllerConsoleUpdateWatch(virLXCControllerConsolePtr consol
_("Unable to remove epoll fd"));
VIR_DEBUG(":fail");
virNetDaemonQuit(console->daemon);
- goto cleanup;
+ return;
}
console->hostEpoll = 0;
}
@@ -1153,7 +1153,7 @@ static void
virLXCControllerConsoleUpdateWatch(virLXCControllerConsolePtr consol
_("Unable to add epoll fd"));
VIR_DEBUG(":fail");
virNetDaemonQuit(console->daemon);
- goto cleanup;
+ return;
}
console->contEpoll = events;
VIR_DEBUG("newHostEvents=%x oldHostEvents=%x", events,
console->contEpoll);
@@ -1165,12 +1165,10 @@ static void
virLXCControllerConsoleUpdateWatch(virLXCControllerConsolePtr consol
_("Unable to remove epoll fd"));
VIR_DEBUG(":fail");
virNetDaemonQuit(console->daemon);
- goto cleanup;
+ return;
}
console->contEpoll = 0;
}
- cleanup:
- return;
}
--
2.24.1