[libvirt] [PATCH 1/7] virCommandAddEnv: Drop inline

Michal Privoznik mprivozn at redhat.com
Thu Mar 3 08:44:36 UTC 2016


This function is big enough for the compiler to be not inlined.
This is the error message I'm seeing:

util/vircommand.c: In function 'virCommandAddEnvFormat':
util/vircommand.c:1257:1: error: inlining failed in call to 'virCommandAddEnv': call is unlikely and code size would grow [-Werror=inline]
 virCommandAddEnv(virCommandPtr cmd, char *env)
 ^
util/vircommand.c:1308:5: error: called from here [-Werror=inline]
     virCommandAddEnv(cmd, env);
     ^

Signed-off-by: Michal Privoznik <mprivozn at redhat.com>
---
 src/util/vircommand.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/util/vircommand.c b/src/util/vircommand.c
index fe7bf34..027cb64 100644
--- a/src/util/vircommand.c
+++ b/src/util/vircommand.c
@@ -1253,7 +1253,7 @@ virCommandRawStatus(virCommandPtr cmd)
  * string like "name=value".  If the named environment variable is
  * already set, then it is replaced in the list.
  */
-static inline void
+static void
 virCommandAddEnv(virCommandPtr cmd, char *env)
 {
     size_t namelen;
-- 
2.4.10




More information about the libvir-list mailing list