]> git.sur5r.net Git - bacula/bacula/commitdiff
Fix bug #2153 with patch submitted by Ana Arruda
authorKern Sibbald <kern@sibbald.com>
Sun, 20 Dec 2015 14:06:03 +0000 (15:06 +0100)
committerKern Sibbald <kern@sibbald.com>
Sun, 20 Dec 2015 14:06:03 +0000 (15:06 +0100)
bacula/src/stored/bextract.c

index e84e55e781e7eb41567cd394a2adb18adce65e05..b0b16df9549a99556f56fc0eaa5c2d6d188996ea 100644 (file)
@@ -162,6 +162,9 @@ int main (int argc, char *argv[])
          }
          while (fgets(line, sizeof(line), fd) != NULL) {
             strip_trailing_junk(line);
+            if (line[0] == 0) { /* skip blank lines */
+               continue;
+            }
             Dmsg1(900, "add_exclude %s\n", line);
             add_fname_to_exclude_list(ff, line);
          }
@@ -177,6 +180,9 @@ int main (int argc, char *argv[])
          }
          while (fgets(line, sizeof(line), fd) != NULL) {
             strip_trailing_junk(line);
+            if (line[0] == 0) { /* skip blank lines */
+               continue;
+            }
             Dmsg1(900, "add_include %s\n", line);
             add_fname_to_include_list(ff, 0, line);
          }