help! crash on UIQ3
| Wed, 2007-08-15 12:43 | |
|
I wrote following C++ code on UIQ3: Could anyone tell me how to fix it? thanks very much. |
|
| Wed, 2007-08-15 12:43 | |
|
I wrote following C++ code on UIQ3: Could anyone tell me how to fix it? thanks very much. |
|
Forum posts: 27
Kern-exec 3 is normally a null pointer exception or something similar.
What could be happening is that your call to OpenL is leaving and that something else that you have created is not getting cleaned up as it is not on the cleanupstack at the time of the leave. Try to see if this is the case and see what error code is returned from your OpenL function.
Forum posts: 3
Thanks for your reply.
My code like following:
class CHttpClient : public CBase, public MHTTPDataSupplier, public MTimeOutNotifier, MUserCancelNotifier,public MHTTPAuthenticationCallback
{
....
private:
RHTTPSession iSess;
....
};
void CHttpClient::ConstructL(const TDesC& aSource, const TDesC& aFilename)
{
iUtils = CHttpClientUtils::NewL(KHttpExampleClientTestName);
// Open the RHTTPSession
iSess.OpenL();
// Install this class as the callback for authentication requests
InstallAuthenticationL(iSess);
User::LeaveIfError(iFileServ.Connect());
// Start a timer
iTimer = CTimeOutTimer::NewL(EPriorityHigh, *this);
iCancelHandle = CUserCancel::NewL(EPriorityHigh, *this);
UserCancelSet_t ucs;
ucs.handle = TM_AU_HTTP_User_Cancel;
ucs.status = &(iCancelHandle->iStatus);
if(!DoCallback(iDownloaderCfg->tls(), Tmu_SET_USER_CANCEL_HANDLE, (TAny* )&ucs))
{
User::Leave(TM_CHTTPCLIENT_USER_CANCEL);
}
iTransObs = CHttpEventHandler::NewL(*iUtils, iTimer, iDownloaderCfg);
iSource.Copy(aSource);
iTransObs->SetFileName(aFilename);
}
There is no return value for RHTTPSession::OpenL(). It crashes before return. Do you have any way to get last error?
Thanks.
Forum posts: 27
put a temporary TRAP around the OpenL to find the error. Also are you deleting iUtils in your destructor?
~b
Forum posts: 286
Are you sure that OpenL is leaving? Where is the iDownloaderCfg getting initialised?
Cheers,
Sri
Forum posts: 3
Thanks for your kindly help.
I change nothing, but it is OK now.