]> git.sur5r.net Git - bacula/bacula/commitdiff
Allow conf file quoted strings to be used in a list
authorKern Sibbald <kern@sibbald.com>
Wed, 21 Nov 2012 12:38:35 +0000 (13:38 +0100)
committerKern Sibbald <kern@sibbald.com>
Sat, 20 Apr 2013 12:51:03 +0000 (14:51 +0200)
bacula/src/lib/lex.c

index cd9d7c5daeeaa70e69c848a75d1c16991b5abd53..c4c78d6cedf14c3f5988838d19378457729d89e5 100644 (file)
@@ -255,7 +255,6 @@ void lex_unget_char(LEX *lf)
    } else {
       lf->col_no--;                   /* Backup to re-read char */
    }
-
 }
 
 
@@ -587,6 +586,13 @@ lex_get_token(LEX *lf, int expect)
          }
          if (ch == '"') {
             token = T_QUOTED_STRING;
+            /*
+             * Since we may be scanning a quoted list of names,
+             *  we get the next character (a comma indicates another
+             *  one), then we put it back for rescanning.
+             */
+            lex_get_char(lf);
+            lex_unget_char(lf);
             lf->state = lex_none;
             break;
          }