--- libaitcfg/src/parse.c 2008/08/28 13:17:41 1.1.1.1 +++ libaitcfg/src/parse.c 2008/09/30 20:00:26 1.1.1.1.2.2 @@ -1,3 +1,11 @@ +/************************************************************************* +* (C) 2008 AITNET ltd - Sofia/Bulgaria - +* by Michael Pounov +* +* $Author: misho $ +* $Id: parse.c,v 1.1.1.1.2.2 2008/09/30 20:00:26 misho Exp $ +* +*************************************************************************/ #include "global.h" #include "aitcfg.h" #include "tools.h" @@ -55,7 +63,9 @@ int ReadConfig(FILE *f, sl_config * __restrict cfg) if (*szLine == '[') { pos = strlen((char*) szLine) - 1; if (szLine[pos] != ']') { +#ifdef __DEBUG cfgDbg(stdout, "WARNING:: Ignore section %s ... not closed breket\n", szLine); +#endif } else { szLine[pos] = 0; strncpy((char*) szSection, (char*) szLine + 1, MAX_STR); @@ -69,7 +79,9 @@ int ReadConfig(FILE *f, sl_config * __restrict cfg) // Devide pairs pos = strchr((char*) szLine, '=') ? strchr((char*) szLine, '=') - (char*) szLine : 0; if (!pos) { +#ifdef __DEBUG cfgDbg(stdout, "WARNING:: Ignore a/v %s ... format error!\n", szLine); +#endif continue; } else { av = malloc(sizeof(struct tagPair));