]> git.ipfire.org Git - thirdparty/nftables.git/commitdiff
don't use internal_location for files specified on command line
authorPatrick McHardy <kaber@trash.net>
Tue, 6 Jul 2010 04:11:18 +0000 (06:11 +0200)
committerPatrick McHardy <kaber@trash.net>
Tue, 6 Jul 2010 04:11:18 +0000 (06:11 +0200)
Fixes strange error messages like:

In file included from internal:0:0-0:
files/examples/sets_and_maps:55:2-2: Error: syntax error, unexpected newline, expecting string

Signed-off-by: Patrick McHardy <kaber@trash.net>
src/main.c

index 8c970b52f165748ec6da5599c31cc8e7891445c6..2a3da3f78b8a0d8a5067d277370d57d67500a569 100644 (file)
@@ -234,7 +234,7 @@ int main(int argc, char * const *argv)
 
                scanner_push_buffer(scanner, &indesc_cmdline, buf);
        } else if (filename != NULL) {
-               if (scanner_read_file(scanner, filename, &internal_location) < 0)
+               if (scanner_read_file(scanner, filename, NULL) < 0)
                        goto out;
        } else if (interactive) {
                cli_init(scanner, &state);