File tree Expand file tree Collapse file tree 2 files changed +3
-4
lines changed
Expand file tree Collapse file tree 2 files changed +3
-4
lines changed Original file line number Diff line number Diff line change @@ -282,7 +282,7 @@ int config_parse(const char *unit,
282282 _cleanup_free_ char * section = NULL , * continuation = NULL ;
283283 _cleanup_fclose_ FILE * ours = NULL ;
284284 unsigned line = 0 , section_line = 0 ;
285- bool section_ignored = false;
285+ bool section_ignored = false, bom_seen = false ;
286286 int r ;
287287
288288 assert (filename );
@@ -328,13 +328,13 @@ int config_parse(const char *unit,
328328 continue ;
329329
330330 l = buf ;
331- if (!( flags & CONFIG_PARSE_REFUSE_BOM ) ) {
331+ if (!bom_seen ) {
332332 char * q ;
333333
334334 q = startswith (buf , UTF8_BYTE_ORDER_MARK );
335335 if (q ) {
336336 l = q ;
337- flags |= CONFIG_PARSE_REFUSE_BOM ;
337+ bom_seen = true ;
338338 }
339339 }
340340
Original file line number Diff line number Diff line change @@ -17,7 +17,6 @@ typedef enum ConfigParseFlags {
1717 CONFIG_PARSE_RELAXED = 1 << 0 ,
1818 CONFIG_PARSE_ALLOW_INCLUDE = 1 << 1 ,
1919 CONFIG_PARSE_WARN = 1 << 2 ,
20- CONFIG_PARSE_REFUSE_BOM = 1 << 3 ,
2120} ConfigParseFlags ;
2221
2322/* Argument list for parsers of specific configuration settings. */
You can’t perform that action at this time.
0 commit comments