Hello, I need interaction between classes and I do it this way:
But it doesnt work, whats wrong there?Code:class tcp_packet { private: public: int *from; ..... }; class con_client { private : int sock; public : DWORD ServeClient(); .... }; ........ DWORD con_client::ServeClient() { ... cResult = recv(this->sock, (char*)RecPck.buff, 1024, 0); if (cResult > 0) { RecPck.size = cResult; RecPck.from = (int*)this; } ... } void tcp_packet_s_handler::read_Login(tcp_packet pck) { con_client *c; c = (con_client*)pck.from; }



LinkBack URL
About LinkBacks


