javamanager/javainstaller/installer/src.s60/utils/sysutil.cpp
changeset 69 773449708c84
parent 35 85266cc22c7f
child 66 2455ef1f5bbc
equal deleted inserted replaced
61:bf7ee68962da 69:773449708c84
    91 (JNIEnv *aEnv, jclass, jint aRepository, jlong aKey, jobjectArray aStringArray)
    91 (JNIEnv *aEnv, jclass, jint aRepository, jlong aKey, jobjectArray aStringArray)
    92 {
    92 {
    93     TUid repositoryUid = { aRepository };
    93     TUid repositoryUid = { aRepository };
    94     CRepository* repository = CRepository::NewLC(repositoryUid);
    94     CRepository* repository = CRepository::NewLC(repositoryUid);
    95     RBuf buf;
    95     RBuf buf;
    96     buf.Create(NCentralRepositoryConstants::KMaxUnicodeStringLength);
       
    97     CleanupClosePushL(buf);
    96     CleanupClosePushL(buf);
       
    97     buf.CreateL(NCentralRepositoryConstants::KMaxUnicodeStringLength);
    98     TInt err = repository->Get(aKey, buf) ;
    98     TInt err = repository->Get(aKey, buf) ;
    99     if (KErrNone == err)
    99     if (KErrNone == err)
   100     {
   100     {
   101         jstring val = aEnv->NewString((const unsigned short*)(buf.Ptr()), buf.Length());
   101         jstring val = aEnv->NewString((const unsigned short*)(buf.Ptr()), buf.Length());
   102         if (NULL == val)
   102         if (NULL == val)