Results 1 to 20 of 27

Thread: QT4.2 corrupted double-linked list and QRadioButton existance

Hybrid View

Previous Post Previous Post   Next Post Next Post
  1. #1
    Join Date
    May 2007
    Location
    Warsaw, Poland
    Posts
    52
    Thanks
    7
    Qt products
    Qt4
    Platforms
    Unix/X11 Windows

    Default Re: QT4.2 corrupted double-linked list and QRadioButton existance

    So yo advise me to change the line:
    Qt Code:
    1. iconv_t cd = createIconv_t(UTF16, 0);
    To copy to clipboard, switch view to plain text mode 
    that is placed in some qt file
    to
    Qt Code:
    1. iconv_t cd = createIconv_t(UTF16, NULL);
    To copy to clipboard, switch view to plain text mode 
    ??
    Just don't get the idea why my actions that are actually a commonplace (initialization of two QRadioButton's and its usage) entail a problem I presented above.
    It's quite bizarre.

  2. #2
    Join Date
    Jan 2006
    Location
    Warsaw, Poland
    Posts
    5,372
    Thanks
    28
    Thanked 976 Times in 912 Posts
    Qt products
    Qt3 Qt4
    Platforms
    Unix/X11 Windows

    Default Re: QT4.2 corrupted double-linked list and QRadioButton existance

    Quote Originally Posted by mtrpoland View Post
    Just don't get the idea why my actions that are actually a commonplace (initialization of two QRadioButton's and its usage) entail a problem I presented above.
    It's quite bizarre.
    Yes, it is. Can you reproduce that stack trace?

  3. #3
    Join Date
    May 2007
    Location
    Warsaw, Poland
    Posts
    52
    Thanks
    7
    Qt products
    Qt4
    Platforms
    Unix/X11 Windows

    Default Re: QT4.2 corrupted double-linked list and QRadioButton existance

    What do you mean by "reproducing the stack trace" ?

  4. #4
    Join Date
    May 2007
    Location
    Warsaw, Poland
    Posts
    52
    Thanks
    7
    Qt products
    Qt4
    Platforms
    Unix/X11 Windows

    Default Re: QT4.2 corrupted double-linked list and QRadioButton existance

    Guys, I strove to circumvent the issue by placing one checkbox instead of two radios. It's like an ufo... Now the program works but I get 'core dumped' after having exited the application. So I assume there is a problem with destruction...

    Qt Code:
    1. (gdb) backtrace
    2. #0 0xffffe410 in __kernel_vsyscall ()
    3. #1 0xb720a770 in raise () from /lib/tls/i686/cmov/libc.so.6
    4. #2 0xb720bef3 in abort () from /lib/tls/i686/cmov/libc.so.6
    5. #3 0xb723fd0b in __fsetlocking () from /lib/tls/i686/cmov/libc.so.6
    6. #4 0xb72478bd in mallopt () from /lib/tls/i686/cmov/libc.so.6
    7. #5 0xb7247a44 in free () from /lib/tls/i686/cmov/libc.so.6
    8. #6 0xb7536e5d in QHashData::freeNode (this=0x8112498, node=0x8124af8)
    9. at tools/qhash.cpp:132
    10. #7 0xb7991abd in QHash<unsigned long, QWidget*>::remove (this=0x8108d30,
    11. akey=@0x812498c)
    12. at ../../include/QtCore/../../src/corelib/tools/qhash.h:450
    13. #8 0xb7982eff in QWidgetPrivate::setWinId (this=0x8124950, id=0)
    14. at kernel/qwidget.cpp:1180
    15. #9 0xb79b8dcc in QWidget::destroy (this=0x81248b8, destroyWindow=true,
    16. destroySubWindows=true) at kernel/qwidget_x11.cpp:782
    17. #10 0xb798866c in ~QWidget (this=0x81248b8) at kernel/qwidget.cpp:1162
    18. #11 0xb7bd7ef1 in ~QAbstractButton (this=0x81248b8)
    19. at widgets/qabstractbutton.cpp:572
    20. #12 0xb7c846e5 in ~QToolButton (this=0x81248b8) at widgets/qtoolbutton.cpp:347
    21. #13 0xb75d4ea1 in QObjectPrivate::deleteChildren (this=0x8123978)
    22. at kernel/qobject.cpp:1823
    23. #14 0xb7988649 in ~QWidget (this=0x8123938) at kernel/qwidget.cpp:1158
    24. #15 0xb7c7e844 in ~QToolBar (this=0x8123938) at widgets/qtoolbar.cpp:472
    25. ---Type <return> to continue, or q <return> to quit---
    26. #16 0xb75d4ea1 in QObjectPrivate::deleteChildren (this=0x810b300)
    27. at kernel/qobject.cpp:1823
    28. #17 0xb7988649 in ~QWidget (this=0xbf85ebf0) at kernel/qwidget.cpp:1158
    29. #18 0xb7c30c21 in ~QMainWindow (this=0xbf85ebf0) at widgets/qmainwindow.cpp:292
    30. #19 0x080527ca in main ()
    To copy to clipboard, switch view to plain text mode 

    The code was altered in mymvc.h:
    Qt Code:
    1. QLabel* label;
    2. QCheckBox* checkOne;
    3. bool caseSensitive;
    4. };
    5.  
    6. #endif
    To copy to clipboard, switch view to plain text mode 

    and in mymvc.cpp:
    Qt Code:
    1. label = new QLabel(tr("Enter a character string below"));
    2. checkOne = new QCheckBox(tr("Case Sensitive"));
    3. checkOne->setChecked(true);
    4. caseSensitive = true;
    5. qvb = new QGridLayout();
    6. connect(checkOne,SIGNAL(toggled(bool)),this,SLOT(setCaseSensitive(bool)));
    7. connect(qcb,SIGNAL(currentIndexChanged(int)),le,SLOT(clear()));
    8. connect(qcb,SIGNAL(currentIndexChanged(int)),qtv,SLOT(filter()));
    9. connect(le,SIGNAL(textChanged(const QString &)),qtv,SLOT(filter()));
    10. connect(model,SIGNAL(fromTVtoVM(int)),this,SIGNAL(doubleClickInTreeView(int)));
    11.  
    12. qvb->addWidget(label,0,0,1,2);
    13. qvb->addWidget(le,1,0);
    14. qvb->addWidget(checkOne,1,1);
    15. qvb->addWidget(qcb,2,0,1,2);
    16. qvb->addWidget(qtv,3,0,1,2);
    17. setLayout(qvb);
    To copy to clipboard, switch view to plain text mode 

  5. #5
    Join Date
    Jan 2006
    Location
    Warsaw, Poland
    Posts
    5,372
    Thanks
    28
    Thanked 976 Times in 912 Posts
    Qt products
    Qt3 Qt4
    Platforms
    Unix/X11 Windows

    Default Re: QT4.2 corrupted double-linked list and QRadioButton existance

    Quote Originally Posted by mtrpoland View Post
    What do you mean by "reproducing the stack trace" ?
    Try running your application again and see whether the stack trace is the same.

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.