[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]

Re: [libvirt] [PATCH v1 13/37] Adapt to VIR_ALLOC and virAsprintf in src/lxc/*



On 07/04/13 14:06, Michal Privoznik wrote:
---
  src/lxc/lxc_cgroup.c     |  4 +--
  src/lxc/lxc_conf.c       |  5 +--
  src/lxc/lxc_container.c  | 77 ++++++++++------------------------------
  src/lxc/lxc_controller.c | 50 +++++++-------------------
  src/lxc/lxc_driver.c     | 92 ++++++++++++------------------------------------
  src/lxc/lxc_fuse.c       | 12 ++-----
  src/lxc/lxc_monitor.c    |  4 +--
  src/lxc/lxc_process.c    | 28 ++++-----------
  8 files changed, 67 insertions(+), 205 deletions(-)

...

diff --git a/src/lxc/lxc_controller.c b/src/lxc/lxc_controller.c
index 88601f1..a927176 100644
--- a/src/lxc/lxc_controller.c
+++ b/src/lxc/lxc_controller.c

...

@@ -1437,11 +1423,9 @@ lxcCreateTty(virLXCControllerPtr ctrl, int *ttymaster,
       * anything other than 0, but let's play it safe.  */
      if ((virAsprintf(ttyName, "/dev/pts/%d", ptyno) < 0) ||
          (virAsprintf(ttyHostPath, "/%s/%s.devpts/%d", LXC_STATE_DIR,
-                    ctrl->def->name, ptyno) < 0)) {
-        virReportOOMError();
+                    ctrl->def->name, ptyno) < 0))
          errno = ENOMEM;
          goto cleanup;

This still needs the block around, it contains two statements.

-    }

      ret = 0;


ACK with the issue above addressed.

Peter


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]