void CMediaClientWsEventObserver::ConstructL() { DEBUG_PRINTF("CMediaClientWsEventObserver::ConstructL +++"); DEBUG_PRINTF("CMediaClientWsEventObserver::ConstructL RWsSession Connect"); TInt err = iWs.Connect(); if (err != KErrNone) { DEBUG_PRINTF2("CMediaClientWsEventObserver::ConstructL Windows Server unavailable, err %d", err); User::Leave(err); } DEBUG_PRINTF("CMediaClientWsEventObserver::ConstructL RWindowGroup Create"); iWindowGroup = RWindowGroup(iWs); User::LeaveIfError(iWindowGroup.Construct((TUint32)this, EFalse)); // Send created window to the background and hide it from the // application switcher iWindowGroup.SetOrdinalPosition( -1, -1000 ); // -1000 = ECoeWinPriorityNeverAtFront DEBUG_PRINTF("CMediaClientWsEventObserver::ConstructL RWindowGroup EnableFocusChangeEvents"); User::LeaveIfError(iWindowGroup.EnableFocusChangeEvents()); UpdateFocusWindowGroupId(ETrue); DEBUG_PRINTF3("CMediaClientWsEventObserver::ConstructL Initial WgId %d Error %d", iWgId, iWgIdError); CActiveScheduler::Add(this); // register with window server to receive focus change notifications DEBUG_PRINTF("CMediaClientWsEventObserver::ConstructL iWs.EventReady()"); iWs.EventReady(&iStatus); DEBUG_PRINTF("CMediaClientWsEventObserver::ConstructL SetActive()"); SetActive(); DEBUG_PRINTF("CMediaClientWsEventObserver::ConstructL ---"); }
void ShopSvc::NotifyGift(UInt32 roleID,UInt32 Gift) { DataBuffer serbuffer(1024); Serializer s( &serbuffer ); Packet p(&serbuffer); serbuffer.Reset(); p.Direction = DIRECT_S_C_REQ; p.SvrType = 1; p.SvrSeq = 1; p.MsgType = 803; p.UniqID = 251; p.PackHeader(); List<UInt32> lrid; s<<Gift; p.UpdatePacketLength(); lrid.push_back(roleID); if(_mainSvc->Service()->Broadcast(lrid, &serbuffer)) { LOG(LOG_ERROR,__FILE__,__LINE__,"Broadcast error!!"); } DEBUG_PRINTF2( "S_C req pkg ----- MsgType[%d],lrid.size[%d] \n", p.MsgType, lrid.size() ); DEBUG_SHOWHEX( p.GetBuffer()->GetReadPtr(), p.GetBuffer()->GetDataSize(), 0, __FILE__, __LINE__ ); }
/** Requests de-initialization of the OpenMAX IL core. It closes the session to the IL Core server. @return OMX_ERRORTYPE */ OMX_ERRORTYPE ROmxILCoreClientSession::DeinitAndClose() { DEBUG_PRINTF(_L8("ROmxILCoreClientSession::DeinitAndClose")); #ifdef SYMBIAN_PERF_TRACE_OMX_IL OstPrintf(TTraceContext(KTracePerformanceTraceUID, EPerFormanceTraceClassification), Ost_OMXIL_Performance::K_OMX_PerformanceTraceFormatMin, Ost_OMXIL_Performance::EMeasurementStart, MAKESTRING(E_DeInit)); #endif #ifdef SYMBIAN_PERF_TRACE_OMX_IL_OSTV1 OstTrace0( TRACE_API, _DeinitAndClose1, "OMX_Deinit >" ); #endif // Param 0 OMX_ERRORTYPE err = OMX_ErrorNone; TPckgBuf<OMX_ERRORTYPE> pckg0; // Param 1 TUint64 serverThreadId = 0; TPckgBuf<TUint64> pckg1; TIpcArgs arg(&pckg0, &pckg1); SendReceive(EOmxILCoreDeinit, arg); // Extract the output values returned from the server. err = pckg0(); serverThreadId = pckg1(); RHandleBase::Close(); // Release server handle so it will exit cleanly. XGlobalILCoreCache* pGlobalILCoreCache = XGlobalILCoreCache::IlCoreCache(); __ASSERT_ALWAYS(pGlobalILCoreCache != NULL, User::Panic(KOmxILCoreClientPanic, KErrNotReady)); pGlobalILCoreCache->SetServerHandle(KNullHandle); RThread serverThread; TInt ret = serverThread.Open(TThreadId(serverThreadId)); if ((KErrNone == ret) && (serverThread.Handle() != KNullHandle)) { DEBUG_PRINTF2(_L8("ROmxILCoreClientSession::DeinitAndClose : serverThread.Handle =[%d]"), serverThread.Handle()); TBool logoffFailed = EFalse; TRequestStatus logoffStatus; serverThread.Logon(logoffStatus); if (logoffStatus == KErrNoMemory) { logoffFailed = ETrue; } if (!logoffFailed) { if (logoffStatus == KRequestPending) { User::WaitForRequest(logoffStatus); } else { serverThread.LogonCancel(logoffStatus); User::WaitForRequest(logoffStatus); } } else { serverThread.Kill(KErrDied); } } serverThread.Close(); #if defined(SYMBIAN_PERF_TRACE_OMX_IL) || defined(SYMBIAN_PERF_TRACE_OMX_IL_OSTV1) OMX_ERRORTYPE omxError = OMX_ErrorNone; if(KErrNone != err) { omxError = OMX_ErrorUndefined; } #endif #ifdef SYMBIAN_PERF_TRACE_OMX_IL TBuf8<1> DeInitStr; OstPrintf(TTraceContext(KTracePerformanceTraceUID, EPerFormanceTraceClassification), Ost_OMXIL_Performance::K_OMX_PerformanceTraceFormat, Ost_OMXIL_Performance::EMeasurementEnd, MAKESTRING(E_DeInit), omxError,&DeInitStr); #endif #ifdef SYMBIAN_PERF_TRACE_OMX_IL_OSTV1 OstTrace1( TRACE_API, _DeinitAndClose2, "OMX_Deinit < ReturnVal=%u", omxError ); #endif return err; }
void IntegrityDeleteFileL(const TDesC& aPath, CIntegrityTreeLeaf* aLeaf, RFs& aFs, RLoader& aLoader, CFileMan& aFileMan) { _LIT(KSysBin, "\\sys\\bin"); RBuf name; name.CreateL(aPath, KMaxFileName); CleanupClosePushL(name); name.Append(aLeaf->Name()); TEntry entry; TInt err = aFs.Entry(name, entry); if (err == KErrNone) { aFs.SetAtt(name, 0, KEntryAttReadOnly); if(entry.IsDir()) { // Make sure to append slash before calling RmDir - otherwise it deletes the parent directory if (name[name.Length()-1] != KPathDelimiter) { name.Append(KPathDelimiter); } User::LeaveIfError(aFileMan.RmDir(name)); } else { if ( aLeaf->Type() == EBackupFile ) // Implies a commit operation is in progress { if ( IsBinary(entry) ) { // Forming the file name so the renamed file can be under sys/bin // for special delete mechanism using RLoader::Delete RBuf tmpName; TParsePtrC fileName(name); tmpName.CreateL(name.Length() + KSysBin.iTypeLength); CleanupClosePushL(tmpName); tmpName.Append(fileName.Drive()); tmpName.Append(KSysBin); tmpName.Append(fileName.Path()); tmpName.Append(fileName.NameAndExt()); DEBUG_PRINTF3(_L("Integrity Services - Renaming %S to %S"), &name, &tmpName); aFileMan.Rename(name,tmpName,CFileMan::EOverWrite); User::LeaveIfError(aLoader.Delete(tmpName)); // Using RLoader delete for paged binaries DEBUG_PRINTF2(_L("Integrity Services - Deleted renamed file %S"), &tmpName); // prune the directory tree if possible RemoveDirectoryTreeL(aFs, tmpName); CleanupStack::PopAndDestroy(&tmpName); } else { User::LeaveIfError(aFileMan.Delete(name)); } } else { // Need to use RLoader Delete which can be used during deletion of Added files during Rollback User::LeaveIfError(aLoader.Delete(name)); } } // prune the directory tree if possible RemoveDirectoryTreeL(aFs, name); } else if(err != KErrNotFound && err != KErrPathNotFound) { DEBUG_PRINTF3(_L("Integrity Services - error %d removing %S"), err, &name); User::Leave(err); } else { DEBUG_PRINTF3(_L("Integrity Services - error %d removing %S"), err, &name); // Check for any renamed files to move it to sys/bin for special delete mechanism RBuf tmpName; TParsePtrC fileName(name); tmpName.CreateL(name.Length() + KSysBin.iTypeLength); CleanupClosePushL(tmpName); tmpName.Append(fileName.Drive()); tmpName.Append(KSysBin); tmpName.Append(fileName.Path()); tmpName.Append(fileName.NameAndExt()); DEBUG_PRINTF2(_L("Integrity Services - Removing %S renamed binary files if any"), &tmpName); aLoader.Delete(tmpName); // prune the directory tree if possible RemoveDirectoryTreeL(aFs, tmpName); CleanupStack::PopAndDestroy(&tmpName); } CleanupStack::PopAndDestroy(&name); }
void CSWICertStoreImpl::SetupWritableCertStoreL() { TInt err = KErrNone; delete iCEntryList; iCEntryList = NULL; // The attached file will be freed as well. delete iCStore; iCStore = NULL; do { // Open the store if it is there RFile file; CDir* entryList = NULL; TPath writableSwiCertStorePath(KSWIWritableCertStorePath); TChar systemDriveChar = RFs::GetSystemDriveChar(); writableSwiCertStorePath[0] = systemDriveChar; if (KErrNone == iFs.GetDir (writableSwiCertStorePath, KEntryAttNormal, ESortByName|EDirsFirst, entryList)) { if (entryList) { CleanupStack::PushL(entryList); TFileName certstoreFile; TInt count = entryList->Count(); if (count > 0) { // Get the highest version certstore file const TEntry& entry = (*entryList)[count - 1]; certstoreFile.Append(writableSwiCertStorePath); certstoreFile.Append(entry.iName); CleanupStack::PopAndDestroy(1, entryList); } else { CleanupStack::PopAndDestroy(1, entryList); // No certstore in this directory // Currently there should not have any directory in this path return; } err = file.Open(iFs, certstoreFile, EFileShareReadersOnly); if (err != KErrNone && err != KErrNotFound) { // Log the error to the system file. DEBUG_PRINTF2(_L8("Error Opening SWI writable certstore: %S."), &certstoreFile); return; } if (err == KErrNone) { // File exist CleanupClosePushL(file); TRAP_IGNORE(iCStore = CPermanentFileStore::FromL(file)); if (iCStore) { CleanupStack::Pop(&file); // now owned by store // Read id of cert list stream TStreamId streamId; RStoreReadStream stream; stream.OpenLC(*iCStore, iCStore->Root()); stream >> streamId; CleanupStack::PopAndDestroy(&stream); // Read the certificate list RStoreReadStream entryStream; entryStream.OpenLC(*iCStore, streamId); iCEntryList = CSWICertStoreEntryList::NewL(entryStream, iToken, iCertIndex); CleanupStack::PopAndDestroy(&entryStream); // Record the writable certstore index // The index will then be used to set the tokenId in the // in handle, so to make the handle unique. iCertIndex += iCEntryList->Count(); } else { // The file format might not comply to the CPermanentFileStore format CleanupStack::PopAndDestroy(&file); // Log the error to the system file. DEBUG_PRINTF2(_L8("Error Opening SWI writable certstore: %S."), &certstoreFile); return; } } } }
void COmxILComponentImpl::InitComponentL() { DEBUG_PRINTF2(_L8("COmxILComponentImpl::InitComponent : Handle[%X]"), ipHandle); __ASSERT_ALWAYS(ipHandle && ipProcessingFunction && ipCallbackManager && ipPortManager && ipConfigManager, User::Panic(KOmxILComponentPanicCategory, 1)); ipFsm = COmxILFsm::NewL(*ipComponent, *ipProcessingFunction, *ipPortManager, *ipConfigManager, *ipCallbackManager); char componentNamebuffer[OMX_MAX_STRINGNAME_SIZE]; OMX_VERSIONTYPE componentVersion; OMX_VERSIONTYPE specVersion; OMX_UUIDTYPE componentUid; ipConfigManager->GetComponentVersion(componentNamebuffer, &componentVersion, &specVersion, &componentUid); TBuf8<128> componentNameBuf8; componentNameBuf8 = const_cast<const TUint8*>(reinterpret_cast<TUint8*>(componentNamebuffer)); iComponentName.CreateL(componentNameBuf8, componentNameBuf8.Length() + 1); iComponentName.PtrZ(); DEBUG_PRINTF2(_L8("COmxILComponentImpl::InitComponent : [%S]"), &iComponentName); // Fill in the component handle ipHandle->nVersion = componentVersion; // The FSM will take care of all the API calls ipHandle->pComponentPrivate = ipFsm; ipHandle->pApplicationPrivate = 0; ipHandle->GetComponentVersion = COmxILComponentImpl::GetComponentVersion; ipHandle->SendCommand = COmxILComponentImpl::SendCommand; ipHandle->GetParameter = COmxILComponentImpl::GetParameter; ipHandle->SetParameter = COmxILComponentImpl::SetParameter; ipHandle->GetConfig = COmxILComponentImpl::GetConfig; ipHandle->SetConfig = COmxILComponentImpl::SetConfig; ipHandle->GetExtensionIndex = COmxILComponentImpl::GetExtensionIndex; ipHandle->GetState = COmxILComponentImpl::GetState; ipHandle->ComponentTunnelRequest = COmxILComponentImpl::ComponentTunnelRequest; ipHandle->UseBuffer = COmxILComponentImpl::UseBuffer; ipHandle->AllocateBuffer = COmxILComponentImpl::AllocateBuffer; ipHandle->FreeBuffer = COmxILComponentImpl::FreeBuffer; ipHandle->EmptyThisBuffer = COmxILComponentImpl::EmptyThisBuffer; ipHandle->FillThisBuffer = COmxILComponentImpl::FillThisBuffer; ipHandle->SetCallbacks = COmxILComponentImpl::SetCallbacks; ipHandle->ComponentDeInit = COmxILComponentImpl::ComponentDeInit; ipHandle->UseEGLImage = COmxILComponentImpl::UseEGLImage; ipHandle->ComponentRoleEnum = COmxILComponentImpl::ComponentRoleEnum; OMX_ERRORTYPE omxRetValue = ipCallbackManager->RegisterComponentHandle(ipHandle); if (OMX_ErrorNone != omxRetValue) { if (OMX_ErrorInsufficientResources == omxRetValue) { User::Leave(KErrNoMemory); } User::Leave(KErrGeneral); } // Let's init the FSM... ipFsm->InitFsm(); }
void InitVF(struct font_entry * tfontp) { struct stat stat; unsigned char* position; int length; struct vf_char *tcharptr; uint32_t c=0; struct font_num *tfontnump; /* temporary font_num pointer */ DEBUG_PRINTF((DEBUG_DVI|DEBUG_VF),"\n OPEN FONT:\t'%s'", tfontp->name); Message(BE_VERBOSE,"<%s>", tfontp->name); if ((tfontp->filedes = open(tfontp->name,O_RDONLY)) == -1) Warning("font file %s could not be opened", tfontp->name); fstat(tfontp->filedes,&stat); tfontp->mmap = mmap(NULL,stat.st_size, PROT_READ, MAP_SHARED,tfontp->filedes,0); if (tfontp->mmap == (unsigned char *)-1) Fatal("cannot mmap VF file <%s> !\n",currentfont->name); if (*(tfontp->mmap) != PRE) Fatal("unknown font format in file <%s> !\n",currentfont->name); if (*(tfontp->mmap+1) != VF_ID) Fatal( "wrong version of vf file! (%d should be 202)\n", (int)*(tfontp->mmap+1)); DEBUG_PRINTF2(DEBUG_VF,"\n VF_PRE:\t'%.*s'", (int)*(tfontp->mmap+2), tfontp->mmap+3); position = tfontp->mmap+3 + *(tfontp->mmap+2); c=UNumRead(position, 4); DEBUG_PRINTF(DEBUG_VF," %d", c); CheckChecksum (tfontp->c, c, tfontp->name); tfontp->designsize = UNumRead(position+4,4); DEBUG_PRINTF(DEBUG_VF," %d", tfontp->designsize); tfontp->type = FONT_TYPE_VF; tfontp->vffontnump=NULL; /* Read font definitions */ position += 8; while(*position >= FNT_DEF1 && *position <= FNT_DEF4) { DEBUG_PRINTF2(DEBUG_VF,"\n @%ld VF:\t%s", (long)(position - tfontp->mmap), dvi_commands[*position]); FontDef(position,tfontp); length = dvi_commandlength[*position]; position += length + *(position + length-1) + *(position+length-2); } /* Default font is the first defined */ tfontnump = tfontp->vffontnump; while (tfontnump->next != NULL) { tfontnump = tfontnump->next; } tfontp->defaultfont=tfontnump->k; /* Read char definitions */ while(*position < FNT_DEF1) { DEBUG_PRINTF(DEBUG_VF,"\n@%ld VF CHAR:\t", (long)(position - tfontp->mmap)); tcharptr=xmalloc(sizeof(struct vf_char)); switch (*position) { case LONG_CHAR: tcharptr->length = UNumRead(position+1,4); c = UNumRead(position+5,4); tcharptr->tfmw = UNumRead(position+9,4); position += 13; break; default: tcharptr->length = UNumRead(position,1); c = UNumRead(position+1,1); tcharptr->tfmw = UNumRead(position+2,3); position += 5; } DEBUG_PRINTF2(DEBUG_VF,"%d %d",tcharptr->length,c); DEBUG_PRINTF(DEBUG_VF," %d",tcharptr->tfmw); tcharptr->tfmw = (int32_t) ((int64_t) tcharptr->tfmw * tfontp->s / (1 << 20)); DEBUG_PRINTF(DEBUG_VF," (%d)",tcharptr->tfmw); if (c > NFNTCHARS) /* Only positive for now */ Fatal("vf character exceeds numbering limit"); tfontp->chr[c] = tcharptr; tcharptr->mmap=position; position += tcharptr->length; } }
TVerdict CCTSYIntegrationTestPhoneStore0002::doTestStepL() /** * @SYMTestCaseID BA-CTSY-INT-PSTR-0002 * @SYMFssID BA/CTSY/PSTR-0002 * @SYMTestCaseDesc Get phone store information and capabilities * @SYMTestPriority High * @SYMTestActions * @SYMTestExpectedResults Pass - Phone store information returned correctly. * @SYMTestType CIT * @SYMTestCaseDependencies live/automatic * * Reason for test: Verify phone store information returned is correct. * * @return - TVerdict code * * $CTSYProblem - Getting the phone store information with * RMobilePhone::GetPhoneStoreInfo is returning * KErrNotSupported. The request is being passed through CTSY * to LTSY, and it is LTSY which is retuning KErrNotSupported. * It is happening for these phonebooks: KETelIccAdnPhoneBook * KETelIccFdnPhoneBook KETelEmergencyNumberStore * KETelOwnNumberStore * KETelIccVoiceMailBox * KETelIccSdnPhoneBook * KETelIccBdnPhoneBook * KETelIccVoiceMailBox * KETelIccSmsStore * * These phonebooks were expected to be supported through this IPC. */ { // // SET UP // // Get the phone. RMobilePhone& phone = iEtelSessionMgr.GetPhoneL(KMainServer, KMainPhone); // // SET UP END // StartTest(); // // TEST START // TExtEtelRequestStatus phoneStoreInfoRequest(phone,EMobilePhoneGetPhoneStoreInfo); CleanupStack::PushL(phoneStoreInfoRequest); RMobilePhoneStore::TMobilePhoneStoreInfoV1 phoneStore; RMobilePhoneStore::TMobilePhoneStoreInfoV1Pckg phoneStorePkg(phoneStore); TInt expectedMinCaps = 0; // Call RMobilePhone::GetPhoneStoreInfo with aStoreName = KETelIccAdnPhoneBook phone.GetPhoneStoreInfo(phoneStoreInfoRequest,phoneStorePkg,KETelIccAdnPhoneBook); ASSERT_EQUALS(WaitForRequestWithTimeOut(phoneStoreInfoRequest, ETimeLong), KErrNone, _L("RMobilePhone::GetPhoneStoreInfo timed out.")); if(phoneStoreInfoRequest.Int() != KErrNotSupported) { ASSERT_EQUALS(phoneStoreInfoRequest.Int(), KErrNone, _L("RMobilePhone::GetPhoneStoreInfo returned error.")); // Check RMobilePhone::GetPhoneStoreInfo returns iTotalEntries > 0 // Check RMobilePhone::GetPhoneStoreInfo returns iUsedEntries >= 0 ASSERT_TRUE( phoneStore.iTotalEntries > 0, _L("RMobilePhone::GetPhoneStoreInfo returns 0 total entries.")); ASSERT_TRUE( phoneStore.iUsedEntries >= 0, _L("RMobilePhone::GetPhoneStoreInfo returns invalid used entries.")); // When aStoreName = KETelIccAdnPhoneBook // Check RMobilePhone::GetPhoneStoreInfo returns iType == EPhoneBookStore // Check RMobilePhone::GetPhoneStoreInfo returns iCaps of RMobilePhoneStore::KCapsReadAccess | RMobilePhoneStore::KCapsWriteAccess | RMobilePhoneStore::KCapsDeleteAll | RMobilePhoneStore::KCapsNotifyEvent ASSERT_EQUALS(phoneStore.iType, RMobilePhoneStore::EPhoneBookStore, _L("RMobilePhone::GetPhoneStoreInfo completed with error.")); expectedMinCaps = RMobilePhoneStore::KCapsReadAccess | RMobilePhoneStore::KCapsWriteAccess | RMobilePhoneStore::KCapsDeleteAll | RMobilePhoneStore::KCapsNotifyEvent; ASSERT_BITS_SET(phoneStore.iCaps, expectedMinCaps, KNoUnwantedBits, _L("RMobilePhone::GetPhoneStoreInfo completed with incorrect caps.")); } else { DEBUG_PRINTF2(_L("RMobilePhone::GetPhoneStoreInfo for KETelIccAdnPhoneBook returned %d"), phoneStoreInfoRequest.Int()); } // Call RMobilePhone::GetPhoneStoreInfo with aStoreName = KETelIccFdnPhoneBook TExtEtelRequestStatus phoneStoreInfoRequest2(phone,EMobilePhoneGetPhoneStoreInfo); CleanupStack::PushL(phoneStoreInfoRequest2); phone.GetPhoneStoreInfo(phoneStoreInfoRequest2,phoneStorePkg,KETelIccFdnPhoneBook); ASSERT_EQUALS(WaitForRequestWithTimeOut(phoneStoreInfoRequest2, ETimeLong), KErrNone, _L("RMobilePhone::GetPhoneStoreInfo timed out.")) if(phoneStoreInfoRequest2.Int() != KErrNotSupported) { ASSERT_EQUALS(phoneStoreInfoRequest2.Int(), KErrNone, _L("RMobilePhone::GetPhoneStoreInfo returned error.")); // Check RMobilePhone::GetPhoneStoreInfo returns iTotalEntries > 0 // Check RMobilePhone::GetPhoneStoreInfo returns iUsedEntries >= 0 ASSERT_TRUE( phoneStore.iTotalEntries > 0, _L("RMobilePhone::GetPhoneStoreInfo returns 0 total entries.")); ASSERT_TRUE( phoneStore.iUsedEntries >= 0, _L("RMobilePhone::GetPhoneStoreInfo returns invalid used entries.")); // When aStoreName = KETelIccFdnPhoneBook // Check RMobilePhone::GetPhoneStoreInfo returns iType == EPhoneBookStore // Check RMobilePhone::GetPhoneStoreInfo returns iCaps of RMobilePhoneStore::KCapsReadAccess | RMobilePhoneStore::KCapsWriteAccess | RMobilePhoneStore::KCapsDeleteAll | RMobilePhoneStore::KCapsNotifyEvent ASSERT_EQUALS(phoneStore.iType, RMobilePhoneStore::EPhoneBookStore, _L("RMobilePhone::GetPhoneStoreInfo completed with error.")); expectedMinCaps = RMobilePhoneStore::KCapsReadAccess | RMobilePhoneStore::KCapsWriteAccess | RMobilePhoneStore::KCapsDeleteAll | RMobilePhoneStore::KCapsNotifyEvent; ASSERT_BITS_SET(phoneStore.iCaps, expectedMinCaps, KNoUnwantedBits, _L("RMobilePhone::GetPhoneStoreInfo completed with incorrect caps.")); } else { DEBUG_PRINTF2(_L("RMobilePhone::GetPhoneStoreInfo for KETelIccAdnPhoneBook returned %d"), phoneStoreInfoRequest.Int()); } // Call RMobilePhone::GetPhoneStoreInfo with aStoreName = KETelEmergencyNumberStore TExtEtelRequestStatus phoneStoreInfoRequest3(phone,EMobilePhoneGetPhoneStoreInfo); CleanupStack::PushL(phoneStoreInfoRequest3); phone.GetPhoneStoreInfo(phoneStoreInfoRequest3,phoneStorePkg,KETelEmergencyNumberStore); ASSERT_EQUALS(WaitForRequestWithTimeOut(phoneStoreInfoRequest3, ETimeLong), KErrNone, _L("RMobilePhone::GetPhoneStoreInfo timed out.")); if(phoneStoreInfoRequest3.Int() != KErrNotSupported) { ASSERT_EQUALS(phoneStoreInfoRequest3.Int(), KErrNone, _L("RMobilePhone::GetPhoneStoreInfo with KETelEmergencyNumberStore completed with incorrect status")); // Check RMobilePhone::GetPhoneStoreInfo returns iTotalEntries > 0 // Check RMobilePhone::GetPhoneStoreInfo returns iUsedEntries >= 0 ASSERT_TRUE( phoneStore.iTotalEntries > 0, _L("RMobilePhone::GetPhoneStoreInfo returns 0 total entries.")); ASSERT_TRUE( phoneStore.iUsedEntries >= 0, _L("RMobilePhone::GetPhoneStoreInfo returns invalid used entries.")); // When aStoreName = KETelEmergencyNumberStore // Check RMobilePhone::GetPhoneStoreInfo returns iType == EEmergencyNumberStore // Check RMobilePhone::GetPhoneStoreInfo returns iCaps of RMobilePhoneStore::KCapsReadAccess ASSERT_EQUALS(phoneStore.iType, RMobilePhoneStore::EEmergencyNumberStore, _L("RMobilePhone::GetPhoneStoreInfo completed with error.")); expectedMinCaps = RMobilePhoneStore::KCapsReadAccess; ASSERT_BITS_SET(phoneStore.iCaps, expectedMinCaps, KNoUnwantedBits, _L("RMobilePhone::GetPhoneStoreInfo completed with incorrect caps.")); } else { DEBUG_PRINTF2(_L("RMobilePhone::GetPhoneStoreInfo for KETelIccAdnPhoneBook returned %d"), phoneStoreInfoRequest.Int()); } // Call RMobilePhone::GetPhoneStoreInfo with aStoreName = KETelOwnNumberStore TExtEtelRequestStatus phoneStoreInfoRequest4(phone,EMobilePhoneGetPhoneStoreInfo); CleanupStack::PushL(phoneStoreInfoRequest4); phone.GetPhoneStoreInfo(phoneStoreInfoRequest4,phoneStorePkg,KETelOwnNumberStore); ASSERT_EQUALS(WaitForRequestWithTimeOut(phoneStoreInfoRequest4, ETimeLong), KErrNone, _L("RMobilePhone::GetPhoneStoreInfo timed out.")); if(phoneStoreInfoRequest4.Int() != KErrNotSupported) { ASSERT_EQUALS(phoneStoreInfoRequest4.Int(), KErrNone, _L("RMobilePhone::GetPhoneStoreInfo returned error.")); // Check RMobilePhone::GetPhoneStoreInfo returns iTotalEntries > 0 // Check RMobilePhone::GetPhoneStoreInfo returns iUsedEntries >= 0 ASSERT_TRUE( phoneStore.iTotalEntries > 0, _L("RMobilePhone::GetPhoneStoreInfo returns 0 total entries.")); ASSERT_TRUE( phoneStore.iUsedEntries >= 0, _L("RMobilePhone::GetPhoneStoreInfo returns invalid used entries.")); // When aStoreName = KETelOwnNumberStore // Check RMobilePhone::GetPhoneStoreInfo returns iType == EOwnNumberStore // Check RMobilePhone::GetPhoneStoreInfo returns iCaps of RMobilePhoneStore::KCapsIndividualEntry | RMobilePhoneStore::KCapsReadAccess | RMobilePhoneStore::KCapsWriteAccess | RMobilePhoneStore::KCapsDeleteAll | RMobilePhoneStore::KCapsNotifyEent | RMobilePhoneStore::KCapsWholeStore ASSERT_EQUALS(phoneStore.iType, RMobilePhoneStore::EOwnNumberStore, _L("RMobilePhone::GetPhoneStoreInfo completed with error.")); expectedMinCaps = RMobilePhoneStore::KCapsIndividualEntry | RMobilePhoneStore::KCapsReadAccess | RMobilePhoneStore::KCapsWriteAccess | RMobilePhoneStore::KCapsDeleteAll | RMobilePhoneStore::KCapsNotifyEvent | RMobilePhoneStore::KCapsWholeStore; ASSERT_BITS_SET(phoneStore.iCaps, expectedMinCaps, KNoUnwantedBits, _L("RMobilePhone::GetPhoneStoreInfo completed with incorrect caps.")); } else { DEBUG_PRINTF2(_L("RMobilePhone::GetPhoneStoreInfo for KETelIccAdnPhoneBook returned %d"), phoneStoreInfoRequest.Int()); } // Call RMobilePhone::GetPhoneStoreInfo with aStoreName = KETelIccVoiceMailBox TExtEtelRequestStatus phoneStoreInfoRequest5(phone,EMobilePhoneGetPhoneStoreInfo); CleanupStack::PushL(phoneStoreInfoRequest5); phone.GetPhoneStoreInfo(phoneStoreInfoRequest5,phoneStorePkg,KETelIccVoiceMailBox); ASSERT_EQUALS(WaitForRequestWithTimeOut(phoneStoreInfoRequest5, ETimeLong), KErrNone, _L("RMobilePhone::GetPhoneStoreInfo timed out.")); if(phoneStoreInfoRequest5.Int() != KErrNotSupported) { ASSERT_EQUALS(phoneStoreInfoRequest5.Int(), KErrNone, _L("RMobilePhone::GetPhoneStoreInfo returned error.")); // Check RMobilePhone::GetPhoneStoreInfo returns iTotalEntries > 0 // Check RMobilePhone::GetPhoneStoreInfo returns iUsedEntries >= 0 ASSERT_TRUE( phoneStore.iTotalEntries > 0, _L("RMobilePhone::GetPhoneStoreInfo returns 0 total entries.")); ASSERT_TRUE( phoneStore.iUsedEntries >= 0, _L("RMobilePhone::GetPhoneStoreInfo returns invalid used entries.")); // When aStoreName = KETelIccVoiceMailBox // Check RMobilePhone::GetPhoneStoreInfo returns iType == EPhoneBookStore // Check RMobilePhone::GetPhoneStoreInfo returns iCaps of RMobilePhoneStore::KCapsReadAccess | RMobilePhoneStore::KCapsWriteAccess | RMobilePhoneStore::KCapsDeleteAll | RMobilePhoneStore::KCapsNotifyEvent ASSERT_EQUALS(phoneStore.iType, RMobilePhoneStore::EPhoneBookStore, _L("RMobilePhone::GetPhoneStoreInfo completed with error.")); expectedMinCaps = RMobilePhoneStore::KCapsReadAccess | RMobilePhoneStore::KCapsWriteAccess | RMobilePhoneStore::KCapsDeleteAll | RMobilePhoneStore::KCapsNotifyEvent; ASSERT_BITS_SET(phoneStore.iCaps, expectedMinCaps, KNoUnwantedBits, _L("RMobilePhone::GetPhoneStoreInfo completed with incorrect caps.")); } else { DEBUG_PRINTF2(_L("RMobilePhone::GetPhoneStoreInfo for KETelIccAdnPhoneBook returned %d"), phoneStoreInfoRequest.Int()); } // Call RMobilePhone::GetPhoneStoreInfo with aStoreName = KETelIccSdnPhoneBook TExtEtelRequestStatus phoneStoreInfoRequest6(phone,EMobilePhoneGetPhoneStoreInfo); CleanupStack::PushL(phoneStoreInfoRequest6); phone.GetPhoneStoreInfo(phoneStoreInfoRequest6,phoneStorePkg,KETelIccSdnPhoneBook); ASSERT_EQUALS(WaitForRequestWithTimeOut(phoneStoreInfoRequest6, ETimeLong), KErrNone, _L("RMobilePhone::GetPhoneStoreInfo timed out.")); if(phoneStoreInfoRequest6.Int() != KErrNotSupported) { ASSERT_EQUALS(phoneStoreInfoRequest6.Int(), KErrNone, _L("RMobilePhone::GetPhoneStoreInfo returned error.")); // Check RMobilePhone::GetPhoneStoreInfo returns iTotalEntries > 0 // Check RMobilePhone::GetPhoneStoreInfo returns iUsedEntries >= 0 ASSERT_TRUE( phoneStore.iTotalEntries > 0, _L("RMobilePhone::GetPhoneStoreInfo returns 0 total entries.")); ASSERT_TRUE( phoneStore.iUsedEntries >= 0, _L("RMobilePhone::GetPhoneStoreInfo returns invalid used entries.")); // When aStoreName = KETelIccSdnPhoneBook // Check RMobilePhone::GetPhoneStoreInfo returns iType == EPhoneBookStore // Check RMobilePhone::GetPhoneStoreInfo returns iCaps of RMobilePhoneStore::KCapsReadAccess ASSERT_EQUALS(phoneStore.iType, RMobilePhoneStore::EPhoneBookStore, _L("RMobilePhone::GetPhoneStoreInfo completed with error.")); expectedMinCaps = RMobilePhoneStore::KCapsReadAccess; ASSERT_BITS_SET(phoneStore.iCaps, expectedMinCaps, KNoUnwantedBits, _L("RMobilePhone::GetPhoneStoreInfo completed with incorrect caps.")); } else { DEBUG_PRINTF2(_L("RMobilePhone::GetPhoneStoreInfo for KETelIccAdnPhoneBook returned %d"), phoneStoreInfoRequest.Int()); } // Call RMobilePhone::GetPhoneStoreInfo with aStoreName = KETelIccBdnPhoneBook TExtEtelRequestStatus phoneStoreInfoRequest7(phone,EMobilePhoneGetPhoneStoreInfo); CleanupStack::PushL(phoneStoreInfoRequest7); phone.GetPhoneStoreInfo(phoneStoreInfoRequest7,phoneStorePkg,KETelIccBdnPhoneBook); ASSERT_EQUALS(WaitForRequestWithTimeOut(phoneStoreInfoRequest7, ETimeLong), KErrNone, _L("RMobilePhone::GetPhoneStoreInfo timed out.")); if(phoneStoreInfoRequest7.Int() != KErrNotSupported) { ASSERT_EQUALS(phoneStoreInfoRequest7.Int(), KErrNone, _L("RMobilePhone::GetPhoneStoreInfo returned error.")); // Check RMobilePhone::GetPhoneStoreInfo returns iTotalEntries > 0 // Check RMobilePhone::GetPhoneStoreInfo returns iUsedEntries >= 0 ASSERT_TRUE( phoneStore.iTotalEntries > 0, _L("RMobilePhone::GetPhoneStoreInfo returns 0 total entries.")); ASSERT_TRUE( phoneStore.iUsedEntries >= 0, _L("RMobilePhone::GetPhoneStoreInfo returns invalid used entries.")); // When aStoreName = KETelIccBdnPhoneBook // Check RMobilePhone::GetPhoneStoreInfo returns iType == EPhoneBookStore // Check RMobilePhone::GetPhoneStoreInfo returns iCaps of 0 ASSERT_EQUALS(phoneStore.iType, RMobilePhoneStore::EPhoneBookStore, _L("RMobilePhone::GetPhoneStoreInfo completed with error.")); expectedMinCaps =0x00; ASSERT_BITS_SET(phoneStore.iCaps, expectedMinCaps,KNoUnwantedBits, _L("RMobilePhone::GetPhoneStoreInfo completed with incorrect caps.")); } else { DEBUG_PRINTF2(_L("RMobilePhone::GetPhoneStoreInfo for KETelIccAdnPhoneBook returned %d"), phoneStoreInfoRequest7.Int()); } // Call RMobilePhone::GetPhoneStoreInfo with aStoreName = KETelIccSmsStore TExtEtelRequestStatus phoneStoreInfoRequest8(phone,EMobilePhoneGetPhoneStoreInfo); CleanupStack::PushL(phoneStoreInfoRequest8); phone.GetPhoneStoreInfo(phoneStoreInfoRequest8,phoneStorePkg,KETelIccSmsStore); ASSERT_EQUALS(WaitForRequestWithTimeOut(phoneStoreInfoRequest8, ETimeVeryLong), KErrNone, _L("RMobilePhone::GetPhoneStoreInfo timed out.")); if(phoneStoreInfoRequest8.Int() != KErrNotSupported) { ASSERT_EQUALS(phoneStoreInfoRequest7.Int(), KErrNone, _L("RMobilePhone::GetPhoneStoreInfo returned error.")); // Check RMobilePhone::GetPhoneStoreInfo returns iTotalEntries > 0 // Check RMobilePhone::GetPhoneStoreInfo returns iUsedEntries >= 0 ASSERT_TRUE( phoneStore.iTotalEntries > 0, _L("RMobilePhone::GetPhoneStoreInfo returns 0 total entries.")); ASSERT_TRUE( phoneStore.iUsedEntries >= 0, _L("RMobilePhone::GetPhoneStoreInfo returns invalid used entries.")); // When aStoreName = KETelIccSmsStore // Check RMobilePhone::GetPhoneStoreInfo returns iType == RMobilePhoneStore::EShortMessageStore // Check RMobilePhone::GetPhoneStoreInfo returns iCaps of RMobilePhoneStore::KCapsIndividualEntry | RMobilePhoneStore::KCapsDeleteAll | RMobilePhoneStore::KCapsReadAccess | RMobilePhoneStore::KCapsWriteAccess | RMobilePhoneStore::KCapsNotifyEvent | RMobilePhoneStore::KCapsWholeStore ASSERT_EQUALS(phoneStore.iType, RMobilePhoneStore::EShortMessageStore, _L("RMobilePhone::GetPhoneStoreInfo completed with error.")); expectedMinCaps = RMobilePhoneStore::KCapsIndividualEntry | RMobilePhoneStore::KCapsDeleteAll | RMobilePhoneStore::KCapsReadAccess | RMobilePhoneStore::KCapsWriteAccess | RMobilePhoneStore::KCapsNotifyEvent | RMobilePhoneStore::KCapsWholeStore; ASSERT_BITS_SET(phoneStore.iCaps, expectedMinCaps, KNoUnwantedBits, _L("RMobilePhone::GetPhoneStoreInfo completed with incorrect caps.")); } else { DEBUG_PRINTF2(_L("RMobilePhone::GetPhoneStoreInfo for KETelIccAdnPhoneBook returned %d"), phoneStoreInfoRequest.Int()); } // // TEST END // StartCleanup(); //phoneStoreInfoRequest //phoneStoreInfoRequest2 //phoneStoreInfoRequest3 //phoneStoreInfoRequest4 //phoneStoreInfoRequest5 //phoneStoreInfoRequest6 //phoneStoreInfoRequest7 //phoneStoreInfoRequest8 CleanupStack::PopAndDestroy(8, &phoneStoreInfoRequest); return TestStepResult(); }
EXPORT_C TBool COmxILImagePort::IsBufferAtHome(OMX_BUFFERHEADERTYPE* apBufferHeader) const { DEBUG_PRINTF2(_L8("COmxILImagePort::IsBufferAtHome : [%X]"), apBufferHeader); return COmxILPort::IsBufferAtHome(apBufferHeader); }
APIRET EXPENTRY FS_CHDIR ( USHORT flag, struct cdfsi *pcdfsi, struct cdfsd *pcdfsd, PSZ pDir, USHORT iCurDirEnd ) { int rc; PVOLUME pVolume; PCURDIR pCurdir; PCURDIR pPrevCurdir; PCURDIR pCurCurdir; DIRENTRY Entry; FLAT flatEntry; FLAT flatBlkDir; struct vpfsi *pvpfsi; struct vpfsd *pvpfsd; PSZ pFullDir; UtilEnterRamfs(); DEBUG_PRINTF2 ("FS_CHDIR flag=%d pDir='%s'", flag, pDir); switch (flag) { case 0: /* allocate new working directory */ FSH_GETVOLPARM (pcdfsi->cdi_hVPB, &pvpfsi, &pvpfsd); pVolume = pvpfsd->pVolume; flatBlkDir = pVolume->flatBlkRootDir; pFullDir = pDir; pDir += 3; if (iCurDirEnd != 0xFFFF) { flatBlkDir = pcdfsd->pCurdir->flatBlkDir; pDir += iCurDirEnd-3; } switch (UtilLocate (&flatBlkDir, &flatEntry, &Entry, pDir)) { case LOC_NOPATH: rc = ERROR_PATH_NOT_FOUND; break; case LOC_FILEENTRY: rc = ERROR_ACCESS_DENIED; break; case LOC_NOENTRY: rc = ERROR_PATH_NOT_FOUND; break; case LOC_DIRENTRY: rc = NearAlloc ((PNEARBLOCK *) &pCurdir, sizeof(CURDIR) + strlen(pFullDir)); if (rc) break; pcdfsd->pCurdir = pCurdir; pCurdir->pNextCurdir = pVolume->pFirstCurdir; pVolume->pFirstCurdir = pCurdir; pCurdir->pVolume = pVolume; pCurdir->flatBlkDir = flatEntry + FIELDOFFSET(DIRENTRY,fblkFile.clusters); strcpy (pCurdir->szDir, pFullDir); rc = NO_ERROR; break; } break; case 1: /* verify working directory - only for removable media? */ rc = ERROR_NOT_SUPPORTED; break; case 2: /* deallocate working directory */ if (pcdfsi != NULL) FSH_GETVOLPARM (pcdfsi->cdi_hVPB, &pvpfsi, &pvpfsd); else pvpfsd = NULL; pCurdir = pcdfsd->pCurdir; pVolume = pCurdir->pVolume; pPrevCurdir = 0; pCurCurdir = pVolume->pFirstCurdir; if (pCurCurdir == 0) { /* All directories already freed, nothing to do */ rc = NO_ERROR; break; } while (pCurCurdir != pCurdir) { #ifdef DEBUG if (pCurCurdir == 0) { debugging = TRUE; DEBUG_PRINTF0 ("\r\n!!! CURDIR not found\r\n"); INT3; } #endif pPrevCurdir = pCurCurdir; pCurCurdir = pCurCurdir->pNextCurdir; } if (pPrevCurdir != 0) pPrevCurdir->pNextCurdir = pCurCurdir->pNextCurdir; else pVolume->pFirstCurdir = pCurCurdir->pNextCurdir; NearFree (pCurCurdir); if (pvpfsd != NULL) pvpfsd->pVolume = scavenge_volume (pVolume); rc = NO_ERROR; break; } DEBUG_PRINTF1 (" => %d\r\n", rc); UtilExitRamfs(); return rc; }
void CUissSession::ServiceL(const RMessage2& aMessage) { DEBUG_PRINTF2(_L8("UISS - Servicing Message Type %d."), aMessage.Function()); TInt func=aMessage.Function(); if (func==KMessageInstall || func==KMessageUninstall #ifdef SYMBIAN_UNIVERSAL_INSTALL_FRAMEWORK || func==KMessageGetComponentInfo #endif ) { // Check if already busy. if (iUissServer.InstallRequest() || iUissServer.InstallWatcher()) { // Already have a main install, say we're busy aMessage.Complete(KErrServerBusy); return; } // Starting a new installation/uninstallation operation // Create a watcher and launch SWIS iUissServer.CreateInstallWatcherL(); // Setup temporary stream for internalisation of arguments from parameter 1 TInt length=aMessage.GetDesLengthL(1); HBufC8* buf=HBufC8::NewMaxLC(length); TPtr8 p=buf->Des(); aMessage.ReadL(1, p); RMemReadStream readStream; readStream.Open(p.Ptr(),length); CleanupClosePushL(readStream); // Call into SWIS to start the Install or uninstall if (func==KMessageInstall) { // Internalise install preferences from readStream/param 1 CInstallPrefs* prefs=CInstallPrefs::NewLC(readStream); RArray<TInt> deviceSupportedLanguages; TInt deviceLanguageCount = readStream.ReadInt32L(); //Streaming set of languages that device supports for(TInt i=0;i<deviceLanguageCount;i++) { deviceSupportedLanguages.AppendL(readStream.ReadInt32L()); } // Start installation with parameters. iUissServer.InstallWatcher()->StartInstallL(*prefs, deviceSupportedLanguages); CleanupStack::PopAndDestroy(prefs); // prefs deviceSupportedLanguages.Close(); } #ifdef SYMBIAN_UNIVERSAL_INSTALL_FRAMEWORK // Call SWIS to get the component info. else if (func == KMessageGetComponentInfo) { // Internalise install preferences from readStream/param 1 CInstallPrefs* prefs=CInstallPrefs::NewLC(readStream); delete iUissServer.iCompInfoBuffer; iUissServer.iCompInfoBuffer = NULL; iUissServer.iCompInfoBuffer = HBufC8::NewL(aMessage.GetDesMaxLength(0)); iUissServer.iCompInfoBufPtr.Set(iUissServer.iCompInfoBuffer->Des()); // Pass on the request and the buffer allocated in the uissclienthandler to the next level. iUissServer.InstallWatcher()->StartGetComponentInfoL(*prefs, iUissServer.iCompInfoBufPtr); CleanupStack::PopAndDestroy(prefs); } #endif else if (func==KMessageUninstall) { // Internalise uninstall package from readStream/param 1 CSisRegistryPackage* package=CSisRegistryPackage::NewLC(readStream); iUissServer.InstallWatcher()->StartUninstall(*package); CleanupStack::PopAndDestroy(package); } iUissServer.SetInstallRequestL(&aMessage, this); CleanupStack::PopAndDestroy(2,buf); // readStream, buf } else if (func==KMessageCompleteDialog) { if (iUissServer.InstallRequest()) { // Already have an outstanding request, this should not happen aMessage.Complete(KErrServerBusy); return; } // We should have a dialog request outstanding. if (!iUissServer.DialogRequest()) { // Internal error User::Leave(KErrInstallerLeave); } // This request completes the dialog request with the data // contained in the message. TInt err = aMessage.Int3(); // Read Leave Code from dialog handler if(err > 0) { // Positive Leave codes are not propogated because some code only considers <0 to be an error err = KErrGeneral; } if(err == KErrNone) { // Dialog handler did not leave so attempt to copy the response. // We use parameter 1 of the message for result reporting TRAP(err, TransferDescriptorL(aMessage, 0, *iUissServer.DialogRequest(), 1)); } iUissServer.DialogRequest()->Complete(err == KErrNone ? iUissServer.DialogRequest()->Function() : err); iUissServer.ClearDialogRequest(); iUissServer.SetInstallRequestL(&aMessage, this); if (iUissServer.DelayedCancel()) { iUissServer.InstallWatcher()->CancelSwis(); iUissServer.SetDelayedCancel(EFalse); } } else if (func==KMessageBufferReallocated) { if (iUissServer.InstallRequest()) { // Already have an outstanding request, this should not happen aMessage.Complete(KErrServerBusy); return; } // We should have a dialog request outstanding. if (!iUissServer.DialogRequest()) { // Internal error User::Leave(KErrInstallerLeave); } // The client has re-issued its request because it was not big // enough to copy the dialog information into. We should have // explicitly provided the size required. TRAPD(err, TransferDescriptorL(*iUissServer.DialogRequest(), 0, aMessage, 0)); // If it was still not big enough something is very wrong. We can't // complete the request with KErrOverflow again, since that will prompt // the client to repeat the request again. if (err == KErrOverflow) { User::Leave(KErrInstallerLeave); } else { User::LeaveIfError(err); } aMessage.Complete(iUissServer.DialogRequest()->Function()); return; } else if (func==KMessageCancel) { // Ignore if an operation is not in progress if (!iUissServer.InstallWatcher()) { // Complete the request to cancel aMessage.Complete(KErrNone); return; } // If the cancel is issued from inside a dialog/event // callback, then we must delay the cancel until the dialog // returns and issues another KMessageCompleteDialog request // to us. An outstanding client KMessageCompleteDialog request // must be outsanding when the operation terminates, so we can // use it to return KErrCancel to the client. if(!iUissServer.InstallRequest()) { // No outstanding client request, so delay cancel. iUissServer.SetDelayedCancel(); } else { // We already have a client request, so can just cancel now. iUissServer.InstallWatcher()->CancelSwis(); } // Complete the request to cancel aMessage.Complete(KErrNone); } else if (func < KMsgSeparatorMaximumSwisMessage && func > KMsgSeparatorMinimumSwisMessage) { // message from swis, try and pass it onto the launcher const RMessage2* installReq = iUissServer.InstallRequest(); if (!installReq) { User::Leave(KErrInstallerLeave); } TRAPD(err, TransferDescriptorL(aMessage, 0, *installReq, 0)); if(err == KErrOverflow) { TInt size = aMessage.GetDesLengthL(0); TPckg<TInt> theSize(size); installReq->WriteL(0, theSize); installReq->Complete(KErrOverflow); iUissServer.ClearInstallRequest(); } else { iUissServer.InstallRequest()->Complete(err == KErrNone ? aMessage.Function() : err); iUissServer.ClearInstallRequest(); User::LeaveIfError(err); } iUissServer.SetDialogRequestL(&aMessage, this); } }