Results 1 to 4 of 4

Thread: Crashing problem. Having trouble debugging.

  1. #1
    Join Date
    Jun 2012
    Posts
    98
    Qt products
    Qt4 Qt/Embedded
    Platforms
    Unix/X11 Windows
    Thanks
    11

    Default Crashing problem. Having trouble debugging.

    I have some debug compilation issues so I've only been able to narrow down that this is a segfault problem (as far as I can tell) and that the form-generated code is causing it; though I don't see any obvious faults. (it seems to crash at the first icon allocation/assignment part of the code, but.. that didn't seem right to me.)

    I've added the relevant folders. Someone who wants to check it out will have to build a quick empty project and call the necessary allocation (such as "object = new BERTKeypad")

    This started happening after I edited the form. The form was originally created in Qt Designer from Creator, and is now being modified via Visual Studio's Qt Designer (there are mild differences in my experience.) I expect some code in there is no longer relevant and was not deleted after I modified the form.

    Thank you for any assistance!
    Attached Files Attached Files

  2. #2
    Join Date
    May 2011
    Posts
    239
    Qt products
    Qt4
    Platforms
    Unix/X11 Symbian S60
    Thanks
    4
    Thanked 35 Times in 35 Posts

    Default Re: Crashing problem. Having trouble debugging.

    Quote Originally Posted by tescrin View Post
    Someone who wants to check it out will have to build a quick empty project and call the necessary allocation (such as "object = new BERTKeypad")
    (If you really wish for debugging help, _you_ have to build and provide a test program and explain where in that you get an error.)

  3. #3
    Join Date
    Jun 2012
    Posts
    98
    Qt products
    Qt4 Qt/Embedded
    Platforms
    Unix/X11 Windows
    Thanks
    11

    Default Re: Crashing problem. Having trouble debugging.

    Made some progress on it. The call causing it was a call to "layout()" or thusly this->layout(), but it seems that that is a container of a Qdialog and not the dialog itself, and thus crashes.

    Does this sound like what Qt would do? Do you have any clue as to why Qt would seg-fault on a QWidget::layout() call?

    EDIT:
    I ended up adding it back in on a sort of... resize function and it no longer segfaults on it. I'm.. still unsure as to why layout() would ever be a problem; but it seems to be resolved.
    Last edited by tescrin; 7th August 2012 at 20:11.

  4. #4
    Join Date
    Sep 2011
    Posts
    1,241
    Qt products
    Qt4
    Platforms
    Windows
    Thanks
    3
    Thanked 127 Times in 126 Posts

    Default Re: Crashing problem. Having trouble debugging.

    layout can return 0
    If you have a problem, CUT and PASTE your code. Do not retype or simplify it. Give a COMPLETE and COMPILABLE example of your problem. Otherwise we are all guessing the problem from a fabrication where relevant details are often missing.

Similar Threads

  1. Trouble Remote Debugging
    By srg4096 in forum Qt for Embedded and Mobile
    Replies: 1
    Last Post: 31st December 2011, 17:45
  2. Crashing without debug mode- No crashing with gdb debugger
    By sujan.dasmahapatra in forum Qt Programming
    Replies: 1
    Last Post: 7th February 2011, 12:27
  3. Qt Creator debugging trouble on Mac OS
    By johnmidd in forum Qt Tools
    Replies: 5
    Last Post: 6th November 2009, 13:34
  4. QSpaceritem problem with crashing
    By moowy in forum Qt Programming
    Replies: 2
    Last Post: 3rd November 2006, 20:52

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.