static struct pathelem *add_dir_maybe(struct pathelem *path)

{

    DIR *dir;



    if ((dir = opendir(path->pathname)) != NULL) {

        struct dirent *dirent;



        while ((dirent = readdir(dir)) != NULL) {

            if (!streq(dirent->d_name,".") && !streq(dirent->d_name,"..")){

                path = add_entry(path, dirent->d_name);

            }

        }

        closedir(dir);

    }

    return path;

}

static struct pathelem *add_dir_maybe(struct pathelem *path)

{

    DIR *dir;



    if ((dir = opendir(path->pathname)) != NULL) {

        struct dirent *dirent;



        while ((dirent = readdir(dir)) != NULL) {

            if (!streq(dirent->d_name,".") && !streq(dirent->d_name,"..")){

                path = add_entry(path, dirent->d_name);

            }

        }

        closedir(dir);

    }

    return path;

}

                path = add_entry(path, dirent->d_name);
static struct pathelem *FUNC_0(struct pathelem *VAR_0)

{

    DIR *dir;



    if ((dir = opendir(VAR_0->pathname)) != NULL) {

        struct VAR_1 *VAR_1;



        while ((VAR_1 = readdir(dir)) != NULL) {

            if (!streq(VAR_1->d_name,".") && !streq(VAR_1->d_name,"..")){

                VAR_0 = add_entry(VAR_0, VAR_1->d_name);

            }

        }

        closedir(dir);

    }

    return VAR_0;

}

static struct pathelem *FUNC_0(struct pathelem *VAR_0)
{ DIR *dir; if ((dir = opendir(VAR_0->pathname)) != NULL) { struct VAR_1 *VAR_1; while ((VAR_1 = readdir(dir)) != NULL) { if (!streq(VAR_1->d_name,".") && !streq(VAR_1->d_name,"..")){ VAR_0 = add_entry(VAR_0, VAR_1->d_name); } } closedir(dir); } return VAR_0; }