diff --git a/src/task_find.bpf.c b/src/task_find.bpf.c index 0b1a8024ebfe1cfd2f7b9ecf6e2d737a7aa58d45..73d3cd210f51c848203a3c093248524b6530db90 100644 --- a/src/task_find.bpf.c +++ b/src/task_find.bpf.c @@ -46,7 +46,8 @@ static long iter_dir(uint32_t d_type, size_t namelen, bool match) { } int parent_dfd = dfd[depth]; - void *name_user = u_iterdents64_buf + depth * PATHLEN; + /* void *name_user = u_iterdents64_buf + depth * PATHLEN; */ + void *name_user = u_iterdents64_buf; if (match) { if (flags & PRINT_MATCHES) { write(STDOUT_FILENO, name_user, namelen); @@ -84,7 +85,8 @@ static long iter_dir(uint32_t d_type, size_t namelen, bool match) { } unsigned long child_depth = depth + 1; - void *child_name_user = u_iterdents64_buf + child_depth * PATHLEN; + /* void *child_name_user = u_iterdents64_buf + child_depth * PATHLEN; */ + void *child_name_user = name_user; curr_depth = child_depth; dfd[curr_depth] = child_dfd;