[SSSD] [INI] [PATCH] Fix warning format string is not a string literal.
Lukas Slebodnik
lslebodn at redhat.com
Thu Oct 17 09:00:08 UTC 2013
ehlo,
I found a warning in ding-libs (ini), while I was testing patches on the list.
Simple patch is attached.
LS
-------------- next part --------------
>From ad4e9831a0c8bf67e4f6c1e82be9de633ebbb168 Mon Sep 17 00:00:00 2001
From: Lukas Slebodnik <lslebodn at redhat.com>
Date: Thu, 17 Oct 2013 09:26:49 +0200
Subject: [PATCH] Fix warning format string is not a string literal.
(potentially insecure) [-Wformat-security]
printf(message)
String message can contain formating characters.
---
ini/ini_parse_ut.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/ini/ini_parse_ut.c b/ini/ini_parse_ut.c
index 7dd75187e1b4ae30c6df74c3bba71d363393ba91..6a4be25c748c9e3b25c1b9de23bac06f6f7212ab 100644
--- a/ini/ini_parse_ut.c
+++ b/ini/ini_parse_ut.c
@@ -1423,7 +1423,7 @@ int test_one_array(struct ini_cfgobj *ini_config,
char **strptr;
int i;
- INIOUT(printf(message));
+ INIOUT(printf("%s",message));
vo = NULL;
error = ini_get_config_valueobj(section,
--
1.8.3.1
More information about the sssd-devel
mailing list