Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. Qt WebKit
  4. QT4.7 : Webkit crash when accessing an Url
Forum Updated to NodeBB v4.3 + New Features

QT4.7 : Webkit crash when accessing an Url

Scheduled Pinned Locked Moved Qt WebKit
5 Posts 2 Posters 3.9k Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • E Offline
    E Offline
    esteban
    wrote on last edited by
    #1

    Dear all,

    I have a QWebView component that crashes at initialization when it tries to access about:blank page and same thing with my simple code :

    @
    QUrl url(URL_UPDATE_FILE);
    QNetworkRequest request(url);
    this->reply = this->manager->get(request); // CRASHES HERE
    @

    with this message :

    HEAP[hadop_qt_widget.exe]: Invalid Address specified to RtlValidateHeap( 01910000, 00FE6070 )

    Does anyone know what it is about ? I'm running Qt 4.7 just compiled and running a VMWare Fusion VM with Windows XP sp3.

    Thank you !

    [edit: fixed code / chetankjain]

    1 Reply Last reply
    0
    • ? This user is from outside of this forum
      ? This user is from outside of this forum
      Guest
      wrote on last edited by
      #2

      I tried on Win XP, but without VMWare, and no issues. Are you sure this->manager is initialized properly?

      Try this, use Designer to add a QWebView to a form, by default you'll see the URL set to about:blank, you can run it without issues, you point to other site, the site opens...

      let me know

      1 Reply Last reply
      0
      • E Offline
        E Offline
        esteban
        wrote on last edited by
        #3

        Hi,

        When I debug my program I can see the manager has a valid address (not null pointer). I don't know if the manager is well initialized I just did a new on it.

        I tried what you suggested and it worked in the designer... I don't know what to think about it. Because when I simply load my program, if I call the widget containing the QWebView it crashes. Though I didn't change anything in the generated ui_MyView class... When I comment the line with "about:blank" in the generated ui_MyView class it works well...

        1 Reply Last reply
        0
        • ? This user is from outside of this forum
          ? This user is from outside of this forum
          Guest
          wrote on last edited by
          #4

          ok, I still suspect the manager is not initialized properly, try to add this line ...

          @
          // in mainwindow.h
          QNetworkAccessManager *manager;
          @

          and in mainwindow.cpp file, way before you do other network stuff,

          @
          manager = new QNetworkAccessManager(this);
          @

          thats all I did ... if it still doesn't work, post your files here (if you can)

          1 Reply Last reply
          0
          • B Offline
            B Offline
            benjamin.poulain
            wrote on last edited by
            #5

            You should post an small example we could run. The code snippet is not enough to find the bug in your code.

            I tend to think like chetankjain, the address of this or manager are invalid.

            1 Reply Last reply
            0

            • Login

            • Login or register to search.
            • First post
              Last post
            0
            • Categories
            • Recent
            • Tags
            • Popular
            • Users
            • Groups
            • Search
            • Get Qt Extensions
            • Unsolved