Results 1 to 12 of 12

Thread: DeleteLater works... but why?

Threaded View

Previous Post Previous Post   Next Post Next Post
  1. #4
    Join Date
    May 2007
    Posts
    90
    Thanks
    40
    Qt products
    Qt4
    Platforms
    Windows

    Default Re: DeleteLater works... but why?

    I should explain more specifically:

    I am placing a new Widget pointer (call it widgetA) in a struct-like QObject class. (all data members public)

    That widgetA performs a function, sends a signal to the struct-like Qobject's creator, who then deletes the widgetA and the struct-like widget.

    The signal being received is a unique variable to that object that allows me to search a list for the object while under the protection of a mutex locker.

    In this case the VS .NET would complain on the very next new memory allocation about a heap corruption.

    If I use deleteLater on the widgetA and then also on the struct-like Qobject, it no longer has this issue.
    Last edited by TheGrimace; 5th June 2007 at 20:42. Reason: updated contents

Similar Threads

  1. How signal-slot works across DLL and application???
    By Shuchi Agrawal in forum Newbie
    Replies: 4
    Last Post: 15th May 2007, 11:24
  2. Replies: 3
    Last Post: 28th January 2007, 17:24
  3. How setEnabled() works on QFrames.
    By Doug Broadwell in forum Newbie
    Replies: 4
    Last Post: 18th October 2006, 19:55
  4. Replies: 3
    Last Post: 1st October 2006, 15:03
  5. How simpletreeview example works?
    By igorko in forum Qt Programming
    Replies: 1
    Last Post: 19th June 2006, 09:59

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Qt is a trademark of The Qt Company.