From 9038ac0c5c4ce8f6cf49e1146a79b633dc534b7d Mon Sep 17 00:00:00 2001 From: Philippe Mathieu-Daudé Date: Thu, 30 Jan 2025 11:57:43 +0100 Subject: overall: Remove unnecessary g_strdup_printf() calls MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Replace g_strdup_printf("%s", value) -> g_strdup(value) to avoid unnecessary string formatting. Signed-off-by: Philippe Mathieu-Daudé Reviewed-by: Daniel P. Berrangé Reviewed-by: Stefan Hajnoczi Reviewed-by: Michael Tokarev Signed-off-by: Michael Tokarev --- plugins/loader.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'plugins/loader.c') diff --git a/plugins/loader.c b/plugins/loader.c index ebc01da9c6..99686b5466 100644 --- a/plugins/loader.c +++ b/plugins/loader.c @@ -128,7 +128,7 @@ static int plugin_add(void *opaque, const char *name, const char *value, /* Will treat arg="argname" as "argname=on" */ fullarg = g_strdup_printf("%s=%s", value, "on"); } else { - fullarg = g_strdup_printf("%s", value); + fullarg = g_strdup(value); } warn_report("using 'arg=%s' is deprecated", value); error_printf("Please use '%s' directly\n", fullarg); -- cgit 1.4.1