]> git.tuebingen.mpg.de Git - adu.git/commitdiff
Merge branch 'master' into next next pu
authorAndre Noll <maan@tuebingen.mpg.de>
Fri, 3 May 2019 22:49:44 +0000 (00:49 +0200)
committerAndre Noll <maan@tuebingen.mpg.de>
Fri, 3 May 2019 22:49:44 +0000 (00:49 +0200)
* master:
  Remove some duplicate const specifiers.
  Add link to author homepage.
  Reword summary text.
  create: Make the directory scan more robust.

README
create.c
format.h
index.html.in
interactive.c
select.c

diff --git a/README b/README
index 9d2783068d798f9135e9d4e33cb458bb45c51b15..5c2b23c8f1798196aa9e6c3ff8dcb006caa4857a 100644 (file)
--- a/README
+++ b/README
@@ -1,6 +1,7 @@
 adu creates a database containing disk usage statistics of a given
-directory. It allows to query that database to quickly retrieve usage
-patterns of subdirectories containing files owned by a given user.
+directory. This database can be queried to quickly retrieve, for
+example, the number and the size of all files in a subdirectory owned
+by a given user.
 
 Four different output modes are available: global list, global summary,
 user list and user summary. The format of the output may be customized
index af5694c4cba8b4148d1b083b5307fb2240335a29..a3373db4ff5d975eb46161512ad8654518abe717 100644 (file)
--- a/create.c
+++ b/create.c
@@ -140,10 +140,9 @@ static int scan_dir(char *dirname, uint64_t *parent_dir_num)
        check_signals();
        DEBUG_LOG("----------------- %llu: %s\n", (long long unsigned)current_dir_num, dirname);
        ret = adu_opendir(dirname, &dir, &cwd_fd);
-       if (ret < 0) {
-               if (ret != -ERRNO_TO_ERROR(EACCES))
-                       return ret;
-               WARNING_LOG("permission denied for %s\n", dirname);
+       if (ret < 0) { /* Non-fatal, continue with next dir */
+               WARNING_LOG("skipping dir %s: %s\n", dirname,
+                       adu_strerror(-ret));
                return 1;
        }
        while ((entry = readdir(dir))) {
index 1e795c6c03a3bd29c4f1049c271d7d2a90bd547c..69d34f53d1932e7e78d8f3ae44d3cab4a7595480 100644 (file)
--- a/format.h
+++ b/format.h
@@ -44,7 +44,7 @@ enum atom_type {
  */
 struct atom {
        /** The name of the directive. */
-       const char const *name;
+       const char *name;
        /** Its type. */
        enum atom_type type;
 };
index ee7bcadc3c1d2f4ce702a2d44603b7b162f5c6ff..7669d6fe9bba60eb772b3fc8cdc880dfebbd6172 100644 (file)
                </h2>
        </center>
 
-       <p> Andr&eacute; Noll, <a
-       href="mailto:maan@tuebingen.mpg.de">maan@tuebingen.mpg.de</a>
-       </p> Comments and bug reports are welcome. Please provide
+       <p> Email: Andr&eacute; Noll, <a
+       href="mailto:maan@tuebingen.mpg.de">maan@tuebingen.mpg.de</a>,
+       Homepage: <a
+       href="http://people.tuebingen.mpg.de/maan/">http://people.tuebingen.mpg.de/maan/</a>
+       </p>
+
+       Comments and bug reports are welcome. Please provide
        enough info such as the version of adu/libosl you are using
        and relevant parts of the logs. Including the string [adu]
        in the subject line is also a good idea.
index 61b4f293562bfe8077f9bcc25f528887605bb7ce..0ed0d8234c06c56c4f217a52d7ddb881d83ad8b7 100644 (file)
@@ -146,7 +146,7 @@ static int icom_set(char *line)
 
 static int exec_interactive_command(char *line)
 {
-       const char const *delim = "\t\n\f\r\v ";
+       const char *delim = "\t\n\f\r\v ";
        int i;
        char *cmd, *args;
        int ret = -E_SYNTAX;
index e0009927d188359c76a78116b7bb6148cd186f6d..a1fc1c20512b3038b0500cf7feefb3891bd76b7a 100644 (file)
--- a/select.c
+++ b/select.c
@@ -168,7 +168,7 @@ struct user_summary_loop_data {
 
 static FILE *output_file;
 
-__printf_1_2 static int output(const char const *fmt, ...)
+__printf_1_2 static int output(const char *fmt, ...)
 {
        va_list argp;
        int ret;