diff options
Diffstat (limited to 'udev_remove.c')
-rw-r--r-- | udev_remove.c | 29 |
1 files changed, 0 insertions, 29 deletions
diff --git a/udev_remove.c b/udev_remove.c index 8351860472..6efa17eb7c 100644 --- a/udev_remove.c +++ b/udev_remove.c @@ -34,35 +34,6 @@ #include "udev_version.h" #include "logging.h" -static int delete_path(const char *path) -{ - char *pos; - int retval; - - pos = strrchr(path, '/'); - while (1) { - *pos = '\0'; - pos = strrchr(path, '/'); - - /* don't remove the last one */ - if ((pos == path) || (pos == NULL)) - break; - - /* remove if empty */ - retval = rmdir(path); - if (errno == ENOENT) - retval = 0; - if (retval) { - if (errno == ENOTEMPTY) - return 0; - err("rmdir(%s) failed: %s", path, strerror(errno)); - break; - } - dbg("removed '%s'", path); - } - return 0; -} - static int delete_node(struct udevice *udev) { char filename[PATH_SIZE]; |