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

[libvirt] [PATCH] Replace virBufferAdd with virBufferAddLit for const string



From: "Daniel P. Berrange" <berrange redhat com>

The statement

        virBufferAdd(buf, "''", 2);

triggers a syntax-check warning

* src/util/buf.c: Replace virBufferAdd with virBufferAddLit
---
 src/util/buf.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

Pushed as a build-breaker fix

diff --git a/src/util/buf.c b/src/util/buf.c
index b7fcf6d..5893e11 100644
--- a/src/util/buf.c
+++ b/src/util/buf.c
@@ -520,7 +520,7 @@ virBufferEscapeShell(virBufferPtr buf, const char *str)
             return;
         }
     } else {
-        virBufferAdd(buf, "''", 2);
+        virBufferAddLit(buf, "''");
         return;
     }
 
-- 
1.7.6.4


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