
<...>
+static int +lxcDomainReboot(virDomainPtr dom, + unsigned int flags) +{ + virLXCDriverPtr driver = dom->conn->privateData; + virLXCDomainObjPrivatePtr priv; + virDomainObjPtr vm; + char *vroot = NULL; + int ret = -1; + int rc; + + virCheckFlags(VIR_DOMAIN_REBOOT_INITCTL | + VIR_DOMAIN_REBOOT_SIGNAL, -1); +
<...>
+ + if (flags == 0 || + (flags & VIR_DOMAIN_REBOOT_INITCTL)) { + if ((rc = virInitctlSetRunLevel(VIR_INITCTL_RUNLEVEL_REBOOT, + vroot)) < 0) { + goto cleanup; + } + if (rc == 0 && flags != 0 && + ((flags & ~VIR_DOMAIN_SHUTDOWN_INITCTL) == 0)) {
((flags & ~VIR_DOMAIN_REBOOT_INITCTL) == 0)) {
+ virReportError(VIR_ERR_OPERATION_UNSUPPORTED, "%s", + _("Container does not provide an initctl pipe")); + goto cleanup; + } + } else { + rc = 0; + } +
<...>