X-Git-Url: http://git.annexia.org/?a=blobdiff_plain;f=daemon%2Fls.c;fp=daemon%2Fls.c;h=9d2ca895771cd0818bdd5cf4570762e590181f61;hb=84fc760439e82e6b3616abd0d1f9bd7d7eb01ec0;hp=8dba1bf41fa9461c9cb1d19768ee6872141e2016;hpb=79b5084f70cb67c37dd7cbe60821a78981fd8d59;p=libguestfs.git diff --git a/daemon/ls.c b/daemon/ls.c index 8dba1bf..9d2ca89 100644 --- a/daemon/ls.c +++ b/daemon/ls.c @@ -30,16 +30,13 @@ #include "actions.h" char ** -do_ls (char *path) +do_ls (const char *path) { char **r = NULL; int size = 0, alloc = 0; DIR *dir; struct dirent *d; - NEED_ROOT (return NULL); - ABS_PATH (path, return NULL); - CHROOT_IN; dir = opendir (path); CHROOT_OUT; @@ -84,15 +81,12 @@ do_ls (char *path) */ char * -do_ll (char *path) +do_ll (const char *path) { int r; char *out, *err; char *spath; - NEED_ROOT (NULL); - ABS_PATH (path, NULL); - spath = sysroot_path (path); if (!spath) { reply_with_perror ("malloc");