I have developed a XMPP client through which i communicate with Open Fire server and able to chat with the persons registered with Open fire server.
When i use Emulator (s60 3rd ed fp-1), the application is working fine continuously with out any connection drop. But when i use my N95, connection is dropped if i am not using for more than 7~10 minutes.
What could be the problem? Why the connection is closed in device and why not in emulator?
Here is my code:
TInt err = iSocketServ.Connect();
TInt err = iSocket.Open(iSocketServ, KAfInet, KSockStream, KProtocolInetTcp);
After checking the Addressand resolving
TInt result = iResolver.Open(*(iSocket->SocketServ()), KAfInet,
iResolver.GetByName(iAddressName, iHostEntry, iStatus);
All the above steps are in Active object.
Then, i am using Write() and RecvOneOrMore() for writing and receiving data respectively.
Any thing i am missing in the above?
Please share your ideas and help me.