Results 1 to 5 of 5

Thread: QwtPolar 1.0.0 examples crash when exiting

  1. #1
    Join Date
    Aug 2010
    Posts
    4
    Qt products
    Qt4
    Platforms
    Unix/X11 Windows

    Default QwtPolar 1.0.0 examples crash when exiting

    Hi there,

    I've just compiled latest QwtPolar (1.0.0) with Qwt 6.0.1 and Qt 4.7.4 on windows using VC9. The two examples crashes when the application ends. It crashes in the function:

    QwtLegend::remove

    Anyone coming across this issue ? Does anyone has an idea to get around this problem.

    Thanks,

    Jean-Charles

  2. #2
    Join Date
    Feb 2006
    Location
    Munich, Germany
    Posts
    3,309
    Thanked 879 Times in 827 Posts
    Qt products
    Qt3 Qt4 Qt/Embedded
    Platforms
    MacOS X Unix/X11 Windows

    Default Re: QwtPolar 1.0.0 examples crash when exiting

    Start your debugger and show the call stack,

    Uwe

  3. #3
    Join Date
    Aug 2010
    Posts
    4
    Qt products
    Qt4
    Platforms
    Unix/X11 Windows

    Default Re: QwtPolar 1.0.0 examples crash when exiting

    From polardemo:

    > qwtd.dll!QwtLegend::remove(const QwtLegendItemManager * plotItem=0x00ac11d0) Ligne 384 + 0x7 octets C++
    qwtpolard.dll!QwtPolarItem::attach(QwtPolarPlot * plot=0x00000000) Ligne 83 C++
    qwtpolard.dll!QwtPolarItemDict::detachItems(int rtti=0, bool autoDelete=true) Ligne 151 C++
    qwtpolard.dll!QwtPolarItemDict::~QwtPolarItemDict( ) Ligne 86 C++
    qwtpolard.dll!QwtPolarPlot::~QwtPolarPlot() Ligne 104 + 0xf octets C++
    polardemo.exe!Plot::~Plot() + 0x10 octets C++
    polardemo.exe!Plot::`scalar deleting destructor'() + 0xf octets C++
    QtCored4.dll!QObjectPrivate::deleteChildren() Ligne 1936 + 0x24 octets C++
    QtGuid4.dll!QWidget::~QWidget() Ligne 1634 C++
    polardemo.exe!QWidget::`scalar deleting destructor'() + 0x10 octets C++
    QtCored4.dll!QObjectPrivate::deleteChildren() Ligne 1936 + 0x24 octets C++
    QtGuid4.dll!QWidget::~QWidget() Ligne 1634 C++
    QtGuid4.dll!QMainWindow::~QMainWindow() Ligne 370 + 0x22 octets C++
    polardemo.exe!MainWindow::~MainWindow() + 0x10 octets C++
    polardemo.exe!main(int argc=1, char * * argv=0x00a07820) Ligne 12 + 0x15 octets C++
    polardemo.exe!WinMain(HINSTANCE__ * instance=0x00400000, HINSTANCE__ * prevInstance=0x00000000, char * __formal=0x00151f23, int cmdShow=1) Ligne 132 + 0x12 octets C++
    polardemo.exe!__tmainCRTStartup() Ligne 578 + 0x35 octets C
    polardemo.exe!WinMainCRTStartup() Ligne 403 C

    and spectrogram:

    > qwtd.dll!QwtLegend::remove(const QwtLegendItemManager * plotItem=0x00ac18f8) Ligne 384 + 0x7 octets C++
    qwtpolard.dll!QwtPolarItem::attach(QwtPolarPlot * plot=0x00000000) Ligne 83 C++
    qwtpolard.dll!QwtPolarItemDict::detachItems(int rtti=0, bool autoDelete=true) Ligne 151 C++
    qwtpolard.dll!QwtPolarItemDict::~QwtPolarItemDict( ) Ligne 86 C++
    qwtpolard.dll!QwtPolarPlot::~QwtPolarPlot() Ligne 104 + 0xf octets C++
    spectrogram.exe!Plot::~Plot() + 0x10 octets C++
    spectrogram.exe!Plot::`scalar deleting destructor'() + 0xf octets C++
    QtCored4.dll!QObjectPrivate::deleteChildren() Ligne 1936 + 0x24 octets C++
    QtGuid4.dll!QWidget::~QWidget() Ligne 1634 C++
    spectrogram.exe!PlotWindow::~PlotWindow() + 0x10 octets C++
    spectrogram.exe!PlotWindow::`scalar deleting destructor'() + 0xf octets C++
    QtCored4.dll!QObjectPrivate::deleteChildren() Ligne 1936 + 0x24 octets C++
    QtGuid4.dll!QWidget::~QWidget() Ligne 1634 C++
    QtGuid4.dll!QMainWindow::~QMainWindow() Ligne 370 + 0x22 octets C++
    spectrogram.exe!MainWindow::~MainWindow() + 0x10 octets C++
    spectrogram.exe!main(int argc=1, char * * argv=0x00a07820) Ligne 67 + 0x15 octets C++
    spectrogram.exe!WinMain(HINSTANCE__ * instance=0x00400000, HINSTANCE__ * prevInstance=0x00000000, char * __formal=0x00151f25, int cmdShow=1) Ligne 132 + 0x12 octets C++
    spectrogram.exe!__tmainCRTStartup() Ligne 578 + 0x35 octets C
    spectrogram.exe!WinMainCRTStartup() Ligne 403 C

    It seems the same issue.

  4. #4
    Join Date
    Feb 2006
    Location
    Munich, Germany
    Posts
    3,309
    Thanked 879 Times in 827 Posts
    Qt products
    Qt3 Qt4 Qt/Embedded
    Platforms
    MacOS X Unix/X11 Windows

    Default Re: QwtPolar 1.0.0 examples crash when exiting

    Well, the crash doesn't happen on my linux box, but my guess is, that the legend is already destructed when the plot items are going to be removed.

    I have added the following line to the destructor of QwtPolarPlot:

    Qt Code:
    1. QwtPolarPlot::~QwtPolarPlot()
    2. {
    3. detachItems( QwtPolarItem::Rtti_PolarItem, autoDelete() );
    4. ...
    5. }
    To copy to clipboard, switch view to plain text mode 
    Please do the same and let me know if the crash is gone.

    Uwe

  5. #5
    Join Date
    Aug 2010
    Posts
    4
    Qt products
    Qt4
    Platforms
    Unix/X11 Windows

    Default Re: QwtPolar 1.0.0 examples crash when exiting

    Hi Uwe,

    I've just tried with this additional line and it doesn't crash any more, well done !
    Thanks a lot for your help.
    Cheers,

    Jean-Charles

Similar Threads

  1. Replies: 6
    Last Post: 29th September 2011, 16:10
  2. Qt 4.7.0 compiles all tools and examples, but they all crash on running
    By prophetofreason in forum Installation and Deployment
    Replies: 0
    Last Post: 13th October 2010, 17:32
  3. QwtPolar or QwtPlot examples do not start
    By giusepped in forum Qwt
    Replies: 2
    Last Post: 15th March 2010, 06:09
  4. Problem running QwtPolar examples
    By MSUdom5 in forum Qwt
    Replies: 4
    Last Post: 11th March 2010, 19:26
  5. Qt Creator - Crash when Exiting
    By BrainB0ne in forum Qt Tools
    Replies: 5
    Last Post: 6th May 2009, 22:05

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
  •  
Digia, Qt and their respective logos are trademarks of Digia Plc in Finland and/or other countries worldwide.