summaryrefslogtreecommitdiff
path: root/sysdeps/linux
diff options
context:
space:
mode:
authorChristian Persch <chpe@gnome.org>2009-05-07 12:57:54 +0200
committerBenoît Dejean <benoit@placenet.org>2009-05-08 14:22:17 +0200
commitf41ab3beed3a2b90475c6057689575413b7b348b (patch)
tree34011764e5ff79fd42c453dbc79a6549723e74ab /sysdeps/linux
parent933683da390c4dd2306ede373966d93181dbafaa (diff)
downloadlibgtop-f41ab3beed3a2b90475c6057689575413b7b348b.tar.gz
Don't printf a string directly but use %s instead
Bug #581725. Signed-off-by: Benoît Dejean <benoit@placenet.org>
Diffstat (limited to 'sysdeps/linux')
-rw-r--r--sysdeps/linux/fsusage.c2
-rw-r--r--sysdeps/linux/glibtop_private.c2
2 files changed, 2 insertions, 2 deletions
diff --git a/sysdeps/linux/fsusage.c b/sysdeps/linux/fsusage.c
index 559ba1f9..13564948 100644
--- a/sysdeps/linux/fsusage.c
+++ b/sysdeps/linux/fsusage.c
@@ -140,7 +140,7 @@ static void linux_2_6_0(glibtop *server, glibtop_fsusage *buf, const char *path)
get_sys_path(server, device, &filename, &format);
- ret = try_file_to_buffer(buffer, sizeof buffer, filename);
+ ret = try_file_to_buffer(buffer, sizeof buffer, "%s", filename);
if (ret < 0) goto out;
diff --git a/sysdeps/linux/glibtop_private.c b/sysdeps/linux/glibtop_private.c
index 041624c7..52c3782c 100644
--- a/sysdeps/linux/glibtop_private.c
+++ b/sysdeps/linux/glibtop_private.c
@@ -124,7 +124,7 @@ int try_file_to_buffer(char *buffer, size_t bufsiz, const char *format, ...)
void
file_to_buffer(glibtop *server, char *buffer, size_t bufsiz, const char *filename)
{
- switch(try_file_to_buffer(buffer, bufsiz, filename))
+ switch(try_file_to_buffer(buffer, bufsiz, "%s", filename))
{
case TRY_FILE_TO_BUFFER_OPEN:
glibtop_error_io_r (server, "open (%s)", filename);