×

Discussion Board

Results 1 to 3 of 3
  1. #1
    Registered User
    Join Date
    Oct 2008
    Posts
    5

    CCalEntry::NewL() question

    CCalEntry::NewL() requires as second parameter a pointer to a "global UID". The new entry takes ownership of the Uid descriptor.Whether the Uid is automatism releaseed while CCalEntry::NewL() Leave?

    CleanupStack::PushL(uid); // Is that Necessary?
    entry = CCalEntry::NewL(entryType, uid, CCalEntry::EMethodNone, 0);
    CleanupStack::Pop(uid);

  2. #2
    Regular Contributor
    Join Date
    Feb 2008
    Location
    Pune, India
    Posts
    340

    Re: CCalEntry::NewL() question

    This article will clear your doubts.
    Regards,
    Sainagakishore Srikantham (Kishore)

    Don't Hope, KNOW!!! ---------- Visit me at http://ssnkishore.blogspot.com ----------

  3. #3
    Registered User
    Join Date
    Dec 2005
    Posts
    1,236

    Re: CCalEntry::NewL() question

    Uid is a memory on the heap and the call you are making
    entry = CCalEntry::NewL(entryType, uid, CCalEntry::EMethodNone, 0);
    is a leaving function there is possibility that it could leave. In case it leave HBufC* Uid you have allocated on the heap goes unclaimed or not deallocated. You have leak in order to avoid that you need to place on CleanupStack.
    Regards,
    Sriky

Similar Threads

  1. Annoying question when dialing by bluetooth
    By tejohf in forum Bluetooth Technology
    Replies: 0
    Last Post: 2003-09-04, 19:56
  2. Newbie question: What is the call stack?
    By advocatee in forum Symbian
    Replies: 2
    Last Post: 2003-06-22, 05:27
  3. Replies: 1
    Last Post: 2003-04-14, 03:14
  4. Replies: 0
    Last Post: 2003-04-07, 09:52
  5. question deleted
    By kiokups in forum General Messaging
    Replies: 1
    Last Post: 2002-09-25, 20:07

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
×