Let the comment character be a constant
This commit is contained in:
parent
9666179b54
commit
40a728c08a
|
@ -26,6 +26,9 @@
|
||||||
#include "System/mutator.h"
|
#include "System/mutator.h"
|
||||||
#include "System/config.h"
|
#include "System/config.h"
|
||||||
|
|
||||||
|
/* constants */
|
||||||
|
#define CONFIG_COMMENT '#'
|
||||||
|
|
||||||
|
|
||||||
/* Config */
|
/* Config */
|
||||||
/* private */
|
/* private */
|
||||||
|
@ -215,7 +218,7 @@ int config_load(Config * config, char const * filename)
|
||||||
}
|
}
|
||||||
/* FIXME unescape backslashes (eg allow multiple lines) */
|
/* FIXME unescape backslashes (eg allow multiple lines) */
|
||||||
for(line = 0; (c = fgetc(fp)) != EOF; line++)
|
for(line = 0; (c = fgetc(fp)) != EOF; line++)
|
||||||
if(c == '#')
|
if(c == CONFIG_COMMENT)
|
||||||
/* skip the comment */
|
/* skip the comment */
|
||||||
while((c = fgetc(fp)) != EOF && c != '\n');
|
while((c = fgetc(fp)) != EOF && c != '\n');
|
||||||
else if(c == '[')
|
else if(c == '[')
|
||||||
|
|
Loading…
Reference in New Issue
Block a user