snmp_pp 使用,报错。
// stdafx.h : 标准系统包含文件的包含文件,
#include <afxsock.h>
// stdafx.cpp : 只包括标准包含文件的源文件
// testIP.pch 将作为预编译头
// stdafx.obj 将包含预编译类型信息
#include "stdafx.h"
#pragma comment(lib, "snmp_pp.lib")
#ifdef __cplusplus
extern "C"
#endif
FILE _iob[3] = {__iob_func()[0], __iob_func()[1], __iob_func()[2]};
// testIPDlg.cpp : 实现文件
#include "stdafx.h"
#include "testIP.h"
#include "testIPDlg.h"
#include "snmp_pp.h"
....
void CtestIPDlg::OnBnClickedButton1()
{
// TODO: 在此添加控件通知处理程序代码
UpdateData(TRUE);
int ret;
Snmp::socket_startup();
Snmp snmp(ret, 0, false); >>>出错。。
Snmp::socket_cleanup();
}
testIP.exe 中的 0x7c93b21a 处未处理的异常: 0xC0000005: 写入位置 0x00000010 时发生访问冲突