Congratulations to our 2022 Qt Champions!

Qextserialport question

  • Anybody using qextserialport lib?

    Why would the code below cause a memory error, it will work fine in main.cpp:

    @Test::Test(QWidget *parent, Qt::WFlags flags)
    : QMainWindow(parent, flags)
    QList<QextPortInfo> ports = QextSerialEnumerator::getPorts();

    Edit : @ tags added by Eddy

  • What exactly is the error you get, how are you instantiating Test?

  • Thanks for trying to help, Error I get is :

    HEAP[Test.exe]: Invalid address specified to RtlValidateHeap( 00910000, 00E97230 )
    Windows has triggered a breakpoint in Test.exe. The break point it shows is at this location in qpalette.cpp file:

    Destroys the palette.
    delete d;

    I instantiate test in main.cpp as:

    @int main(int argc, char *argv[])
    QApplication a(argc, argv);

    Test w;;
    return a.exec();

  • Please be sure to wrap all your code in @ tags. Thanks!

Log in to reply