equal
deleted
inserted
replaced
19 // INCLUDES |
19 // INCLUDES |
20 #include <s32mem.h> |
20 #include <s32mem.h> |
21 #include <appversion.h> |
21 #include <appversion.h> |
22 #include "javaregconverter.h" |
22 #include "javaregconverter.h" |
23 #include "javaregproperty.h" |
23 #include "javaregproperty.h" |
|
24 #include "javasymbianoslayer.h" |
24 #include "logger.h" |
25 #include "logger.h" |
25 |
26 |
26 using namespace Java::Manager::Registry; |
27 using namespace Java::Manager::Registry; |
27 |
28 |
28 // The size needed to write a TAppVersion in a descriptor |
29 // The size needed to write a TAppVersion in a descriptor |
260 // |
261 // |
261 void JavaRegConverter::GetUnicodeDescriptorsL( |
262 void JavaRegConverter::GetUnicodeDescriptorsL( |
262 const TDesC& aValue, |
263 const TDesC& aValue, |
263 RPointerArray<HBufC>& aDescriptors) |
264 RPointerArray<HBufC>& aDescriptors) |
264 { |
265 { |
|
266 CleanupResetAndDestroyPushL(aDescriptors); // If method leaves this will clean leaked memory |
265 TInt32 count; |
267 TInt32 count; |
266 |
268 |
267 HBufC8* buf = HBufC8::NewLC(aValue.Length()); |
269 HBufC8* buf = HBufC8::NewLC(aValue.Length()); |
268 TPtr8 ptr = buf->Des(); |
270 TPtr8 ptr = buf->Des(); |
269 ptr.Copy(aValue); |
271 ptr.Copy(aValue); |
281 CleanupStack::Pop(desc); |
283 CleanupStack::Pop(desc); |
282 } |
284 } |
283 |
285 |
284 CleanupStack::PopAndDestroy(&stream); |
286 CleanupStack::PopAndDestroy(&stream); |
285 CleanupStack::PopAndDestroy(buf); |
287 CleanupStack::PopAndDestroy(buf); |
|
288 CleanupStack::Pop(&aDescriptors); |
286 } |
289 } |
287 |
290 |
288 // --------------------------------------------------------------------------- |
291 // --------------------------------------------------------------------------- |
289 // JavaRegConverter::StoreUnicodeDescriptorsL |
292 // JavaRegConverter::StoreUnicodeDescriptorsL |
290 // --------------------------------------------------------------------------- |
293 // --------------------------------------------------------------------------- |