#include "extern.h"
using std::ifstream;
+using std::cerr;
+using std::endl;
void load_config_file(char *config);
void unload_config_file();
if (infile.fail())
{
log("Error opening %s", config);
+ cerr << "Error opening " << config << endl;
return;
}
while (infile.getline(buf, 1024, '\n'))
{
#ifdef DEBUGMODE
- log("Buf: %s", buf);
+ log("Config file entry buf: %s", buf);
#endif
if (buf[0] == '#' || buf[0] == ' ' || buf[0] == '\0' || buf[0] == '\n' || buf[0] == '\r')
{
value = strtok(NULL, "");
log("You should read the entire %s file!", config);
+ cerr << "You should read the entire " << config << " file!"
+ << endl;
exit(0);
}
if (stricmp(directive, "S_GAMESERV") == 0)
{
#ifdef DEBUGMODE
log("Unknown Directive. Buffer: %s", buf);
+ cerr << "Unknown " << config << " directive. Buffer: "
+ << buf << endl;
#endif
continue;
}