www.pudn.com > IEC104MasterSlave.rar > SocketException.h, change:2013-03-01,size:782b


// SocketException.h: interface for the SocketException class. 
// 
////////////////////////////////////////////////////////////////////// 
 
#if !defined(AFX_SOCKETEXCEPTION_H__3CAEC41D_E60F_429E_AFFE_E53E75D1DC8A__INCLUDED_) 
#define AFX_SOCKETEXCEPTION_H__3CAEC41D_E60F_429E_AFFE_E53E75D1DC8A__INCLUDED_ 
#include <string.h> 
 
#if _MSC_VER > 1000 
#pragma once 
#endif // _MSC_VER > 1000 
 
class SocketException   
{ 
public: 
	SocketException(); 
	virtual ~SocketException(); 
	SocketException(const char*msg, int errcode=-1)	{init(msg,errcode);} 
	 
protected: 
	void init(const char*a, int b){strncpy(msg, a, 0); errcode = b;} 
	 
private: 
	char msg[1024]; 
	int	errcode; 
 
}; 
 
#endif // !defined(AFX_SOCKETEXCEPTION_H__3CAEC41D_E60F_429E_AFFE_E53E75D1DC8A__INCLUDED_)