Serilization : Using serialization with socket++ for serializing objects over TCP connections : Problem

Hi All,
I using boost::archive and socket++ libraries for serializing objects
over TCP connections. Socket++ provides iosockinet class which is a
derivative of iostream that supports i/o with two different buffers.
Upon binding the iosockinet to a port I assign it to binary_iarchive
and oarchive upon doing so .. the program aborts immediately. I am not
sure what is causing this problem. Any help in this would be
appreciated.
================= serialize_common.h ========================
class serialize_common {
private:
friend class boost::serialization::access;
string name;
int iVal;
long lVal;
unsigned int uiVal;
float fVal;
double dVal;
template <class Archive>
void serialize(Archive& ar, const unsigned int version) {
ar & name;
ar & iVal;
ar & lVal;
ar & uiVal;
ar & fVal;
ar & dVal;
}
public:
. . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
. . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
. . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
};
================= test.cpp ==================================
/*
1. sockinetbuf is derived from sockbuf
2. iosockinet is derived from iosockstream which inturn is
derived from iostream
*/
#include
participants (1)
-
nitin motgi