From: Florian Forster Date: Sat, 21 Apr 2007 09:55:20 +0000 (+0200) Subject: src/liboconfig: Imported liboconfig 0.1.2. X-Git-Tag: collectd-4.0.0~70 X-Git-Url: https://git.verplant.org/?a=commitdiff_plain;h=c38afefcecf256234b87107a48bfeb509798fac4;p=collectd.git src/liboconfig: Imported liboconfig 0.1.2. --- diff --git a/src/liboconfig/oconfig.c b/src/liboconfig/oconfig.c index f8d18499..2bb80cc9 100644 --- a/src/liboconfig/oconfig.c +++ b/src/liboconfig/oconfig.c @@ -24,11 +24,15 @@ #include "oconfig.h" -/* Functions provided by the scanner */ -void yyset_in (FILE *); +extern FILE *yyin; oconfig_item_t *ci_root; +static void yyset_in (FILE *fd) +{ + yyin = fd; +} /* void yyset_in */ + oconfig_item_t *oconfig_parse_fh (FILE *fh) { int status; diff --git a/src/liboconfig/scanner.l b/src/liboconfig/scanner.l index aa111a29..646bbc63 100644 --- a/src/liboconfig/scanner.l +++ b/src/liboconfig/scanner.l @@ -22,6 +22,7 @@ #include "aux_types.h" #include "parser.h" %} +%option yylineno WHITE_SPACE [\ \t\b] QUOTED_STRING \"([^\\"]+|\\.)*\" UNQUOTED_STRING [0-9A-Za-z_]+