aboutsummaryrefslogtreecommitdiff
path: root/livetree.c
diff options
context:
space:
mode:
Diffstat (limited to 'livetree.c')
-rw-r--r--livetree.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/livetree.c b/livetree.c
index 7eacd02..dfbae65 100644
--- a/livetree.c
+++ b/livetree.c
@@ -526,7 +526,7 @@ struct node *get_node_by_path(struct node *tree, const char *path)
p = strchr(path, '/');
for_each_child(tree, child) {
- if (p && strprefixeq(path, p - path, child->name))
+ if (p && strprefixeq(path, (size_t)(p - path), child->name))
return get_node_by_path(child, p+1);
else if (!p && streq(path, child->name))
return child;