]> git.ipfire.org Git - thirdparty/rsync.git/commitdiff
Tweak a couple var names.
authorWayne Davison <wayne@opencoder.net>
Sun, 5 Jul 2020 16:33:03 +0000 (09:33 -0700)
committerWayne Davison <wayne@opencoder.net>
Sun, 5 Jul 2020 21:22:09 +0000 (14:22 -0700)
options.c

index d498e2261051cc9f9e20b0ea4a04ab9cb052e58f..956d6e33ee715d0080016c0f84dedc8b8d561b22 100644 (file)
--- a/options.c
+++ b/options.c
@@ -586,7 +586,7 @@ static void print_info_flags(enum logcode f)
        STRUCT_STAT *dumstat;
        char line_buf[75];
        int line_len, j;
-       char *capabilities[] = {
+       char *info_flags[] = {
 
        "*Capabilities",
 
@@ -685,20 +685,20 @@ static void print_info_flags(enum logcode f)
        };
 
        for (line_len = 0, j = 0; ; j++) {
-               char *cap = capabilities[j], *next_cap = cap ? capabilities[j+1] : NULL;
-               int cap_len = cap && *cap != '*' ? strlen(cap) : 1000;
-               int need_comma = next_cap && *next_cap != '*' ? 1 : 0;
-               if (line_len && line_len + 1 + cap_len + need_comma >= (int)sizeof line_buf) {
+               char *str = info_flags[j], *next_nfo = str ? info_flags[j+1] : NULL;
+               int str_len = str && *str != '*' ? strlen(str) : 1000;
+               int need_comma = next_nfo && *next_nfo != '*' ? 1 : 0;
+               if (line_len && line_len + 1 + str_len + need_comma >= (int)sizeof line_buf) {
                        rprintf(f, "   %s\n", line_buf);
                        line_len = 0;
                }
-               if (!cap)
+               if (!str)
                        break;
-               if (*cap == '*') {
-                       rprintf(f, "%s:\n", cap+1);
+               if (*str == '*') {
+                       rprintf(f, "%s:\n", str+1);
                        continue;
                }
-               line_len += snprintf(line_buf+line_len, sizeof line_buf - line_len, " %s%s", cap, need_comma ? "," : "");
+               line_len += snprintf(line_buf+line_len, sizeof line_buf - line_len, " %s%s", str, need_comma ? "," : "");
        }
 }