I have an application that transfers image from a mobile phone to a nearby PC with a special server through Bluetooth. It works fine in most cases, but sometimes if the picture is large or if there are a lot of Bluetooth traffic the phone crashes.
The screen slowly fades out and the phone restarts. However, when it restarts you do not need to type in your password again. The error happens on Nokia 6680, 7610 , 6630.
I would appreciate any suggestions or ideas.
// The code that connects the device to the PC.
void CBluetoothClient::ConnectToServerL(const TBTDevAddr& aBTDevAddr, const TInt aPort)
iState = EConnecting;
Observer.InfoMessage(_L("Connecting to Service"));
// A part of RunL()
TInt rest = iMessage->Size() - iWritePos;
TInt len = KWriteBufferSize;
TPtrC8 data = iMessage->Mid(iWritePos,len);