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

[Libvir] [PATCH] Useless statement in openvzGetVPSInfo



Hi,
the patch is now in attachement..

I think, that the statement
    if (!vm)
         vm = *pnext;
will never be executed: in the first pass, we have already check this a few lines before; in next passes, vm remains the same...

Anton

diff --git a/src/openvz_conf.c b/src/openvz_conf.c
index 79d1e90..c5b6588 100644
--- a/src/openvz_conf.c
+++ b/src/openvz_conf.c
@@ -530,9 +530,6 @@ openvzGetVPSInfo(virConnectPtr conn) {
             goto error;
         }
 
-        if(!vm)
-            vm = *pnext;
-
         if (fscanf(fp, "%d %s\n", &veid, status) != 2) {
 	    error(conn, VIR_ERR_INTERNAL_ERROR,
 	          "Failed to parse vzlist output");

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