[AGENT++] LOGGING mechanism for AGENT++,snmp++

Jochen Katz katz at agentpp.com
Fri Jul 6 13:25:14 CEST 2007


Hi,

> Yes the file has re-created if i delete it. Also the LOGS are coming in a stdout console.
>  Am i missing anything here?

nothing that I am aware of. Logs should only be printed to stdout if the
file cannot be opened/created.

I verified that it works with the patch for snmpNext.cpp at the end of
this mail.

I can only suggest that you run your program in debug mode and set a
break point in AgentLogImpl::set_dest(const char* fname)

Regards,
  Jochen

@@ -97,6 +97,8 @@
          return 1;
    }

+   DefaultLog::init(new AgentLogImpl("logger.txt"));
+
    // Set filter for logging
    DefaultLog::log()->set_filter(ERROR_LOG, 7);
    DefaultLog::log()->set_filter(WARNING_LOG, 7);




More information about the AGENTPP mailing list