It is not safe to use a variable for printf formatting.

Signed-off-by: MORITA Kazutaka <[email protected]>
---
 collie/treeview.c |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/collie/treeview.c b/collie/treeview.c
index 2f21dd7..556964d 100644
--- a/collie/treeview.c
+++ b/collie/treeview.c
@@ -153,7 +153,7 @@ static void _dump_tree(struct vdi_tree *current, int level, 
int first, int last)
        if (current->highlight)
                printf(TEXT_BOLD);
 
-       printf(current->label);
+       printf("%s", current->label);
 
        if (current->highlight)
                printf(TEXT_NORMAL);
@@ -190,7 +190,7 @@ void dump_tree(void)
        }
 
        list_for_each_entry(vdi, &root->children, siblings) {
-               printf(vdi->name);
+               printf("%s", vdi->name);
                more[0] = 0;
                width[0] = strlen(vdi->name);
                _dump_tree(vdi, 1, 1, 1);
-- 
1.5.6.5

-- 
sheepdog mailing list
[email protected]
http://lists.wpkg.org/mailman/listinfo/sheepdog

Reply via email to