]> git.tue.mpg.de Git - adu.git/commitdiff
scan_dir(): Print error reason if lstat() failed.
authorAndre Noll <maan@systemlinux.org>
Thu, 5 Jun 2008 16:56:58 +0000 (18:56 +0200)
committerAndre Noll <maan@systemlinux.org>
Thu, 5 Jun 2008 16:56:58 +0000 (18:56 +0200)
create.c

index 638ba19d28dc5fe3258ea71eabb48514fe9bbb56..5c243d8f507a92efc93b2464b53de5ac5af732fe 100644 (file)
--- a/create.c
+++ b/create.c
@@ -143,8 +143,8 @@ static int scan_dir(char *dirname, uint64_t *parent_dir_num)
                if (!strcmp(entry->d_name, ".."))
                        continue;
                if (lstat(entry->d_name, &s) == -1) {
-                       WARNING_LOG("lstat error for %s/%s\n", dirname,
-                               entry->d_name);
+                       WARNING_LOG("lstat error for %s/%s (%s)\n",
+                               dirname, entry->d_name, strerror(errno));
                        continue;
                }
                m = s.st_mode;