netsnmptrapd 's win32 c++ language's problem
麻 雪蛟 <[email protected]>
| Newsgroups | gmane.network.net-snmp.user |
|---|---|
| Message-ID | <[email protected]> |
Hello..
I download netsnmp5.2.2 release version..and I did following things
<1> modify libsnmptrapd's snmptrapd.c file
a> delete #define WIN32SERVICE line(I don't want to use windows
service)
b> delete main function (excluding collision)
c> compile and link libsnmptrapd(use windows vc++6.0, following
all the same)
<2> modify snmptrapd program's snmptrapd.c filename to snmptrapd.cpp
<3> add extern "C" to some function declaration(for avoid link error)
<4> compile and link snmptrapd pragram
but when I run my new snmptrapd program, the problems come out:
a> when my snmptrapd open for about 5minutes, it couldn't receive
trap messages anymore, I debugged this problem, I found the block reason is
for snmp_logging.c's log_handler_stdouterr's "printf" funtion, when the
code excute to printf line, it block, and no action..
b>at above circumstances, when I press "ctrl+c", it could print
last message
could someone tell me why?? does my porting has error?? or netsnmp's
trapd has some error??
expert my question's answer...................;-)
Best Regards
Anders
_________________________________________________________________
涓虹杩琛浜ゆ锛璇蜂娇 MSN Messenger: http://messenger.msn.com/cn
-------------------------------------------------------
This SF.net email is sponsored by: Splunk Inc. Do you grep through log files
for problems? Stop! Download the new AJAX search engine that makes
searching your log files as easy as surfing the web. DOWNLOAD SPLUNK!
http://ads.osdn.com/?ad_id=7637&alloc_id=16865&op=click
_______________________________________________
Net-snmp-users mailing list
[email protected]
Please see the following page to unsubscribe or change other options:
https://lists.sourceforge.net/lists/listinfo/net-snmp-users