Uploaded image for project: 'Qt'
  1. Qt
  2. QTBUG-24717

Commit ff25691d00d634068c6389f8f1607d7cc95ac5be makes qtdeclarative autotests crash

    XMLWordPrintable

Details

    • Bug
    • Resolution: Done
    • P2: Important
    • 5.0.0
    • 5.0.0
    • Network
    • None
    • c68737add39360040e5b0cd93f01f229d6a8bbc9

    Description

      For example tests/auto/quick/qquickborderimage.

      The problem seems to be that QHttpNetworkConnection::setTransparentProxy() calls setProxy() on a channel that hasn't been initialized. This causes the subsequent call to QHttpNetworkConnection::transparentProxy() to crash since d->channels[0].socket is null.

      Backtrace:

      Program received signal EXC_BAD_ACCESS, Could not access memory.
      Reason: KERN_INVALID_ADDRESS at address: 0x0000000000000008
      [Switching to process 40713 thread 0x8607]
      QScopedPointer<QObjectData, QScopedPointerDeleter<QObjectData> >::data (this=0x8) at qscopedpointer.h:132
      132 return d;
      (gdb) bt
      #0 QScopedPointer<QObjectData, QScopedPointerDeleter<QObjectData> >::data (this=0x8) at qscopedpointer.h:132
      #1 0x0000000102e72d45 in qGetPtrHelper (p=@0x8) at qglobal.h:1357
      #2 0x0000000102e733dc in QAbstractSocket::d_func (this=0x0) at qabstractsocket.h:220
      #3 0x0000000102e72313 in QAbstractSocket::proxy (this=0x0) at socket/qabstractsocket.cpp:2895
      #4 0x0000000102da434f in QHttpNetworkConnection::transparentProxy (this=0x104529fc0) at access/qhttpnetworkconnection.cpp:1200
      #5 0x0000000102daa0c3 in QHttpNetworkConnectionChannel::ensureConnection (this=0x10484a0d8) at access/qhttpnetworkconnectionchannel.cpp:646
      #6 0x0000000102da3a46 in QHttpNetworkConnectionPrivate::startNetworkLayerStateLookup (this=0x10452b120) at access/qhttpnetworkconnection.cpp:1087
      #7 0x0000000102da30d0 in QHttpNetworkConnectionPrivate::_q_hostLookupFinished (this=0x10452b120,
      info=<value temporarily unavailable, due to optimizations>) at access/qhttpnetworkconnection.cpp:1036
      #8 0x0000000102da46e3 in QHttpNetworkConnection::qt_static_metacall (_o=0x104529fc0, _c=QMetaObject::InvokeMetaMethod, _id=1, _a=0x104529c30)
      at moc_qhttpnetworkconnection_p.cpp:54
      #9 0x0000000103d72f9e in QMetaCallEvent::placeMetaCall (this=0x10452c720, object=0x104529fc0) at qobject.cpp:446
      #10 0x0000000103d74b71 in QObject::event (this=0x104529fc0, e=0x10452c720) at qobject.cpp:1024
      #11 0x0000000101e1e3f5 in QApplicationPrivate::notify_helper (this=0x1058013c0, receiver=0x104529fc0, e=0x10452c720) at qapplication.cpp:3713
      #12 0x0000000101e20878 in QApplication::notify (this=0x7fff5fbff9b0, receiver=0x104529fc0, e=0x10452c720) at qapplication.cpp:3172
      #13 0x0000000103d318ef in QCoreApplication::notifyInternal (this=0x7fff5fbff9b0, receiver=0x104529fc0, event=0x10452c720) at qcoreapplication.cpp:694
      #14 0x0000000103d36244 in QCoreApplication::sendEvent (receiver=0x104529fc0, event=0x10452c720) at qcoreapplication.h:206
      #15 0x0000000103d32da0 in QCoreApplicationPrivate::sendPostedEvents (receiver=0x0, event_type=0, data=0x105c3e820) at qcoreapplication.cpp:1293
      #16 0x0000000103db8a63 in QEventDispatcherUNIX::processEvents (this=0x1059c6750, flags=

      {i = 36}) at qeventdispatcher_unix.cpp:586
      #17 0x0000000103d2cf2c in QEventLoop::processEvents (this=0x10cb80dc8, flags={i = 36}

      ) at qeventloop.cpp:135
      #18 0x0000000103d2d148 in QEventLoop::exec (this=0x10cb80dc8, flags=

      {i = 0}

      ) at qeventloop.cpp:211
      #19 0x0000000103af5630 in QThread::exec (this=0x105c3e560) at qthread.cpp:469
      #20 0x0000000103af5865 in QThread::run (this=0x105c3e560) at qthread.cpp:536
      #21 0x0000000103afd29c in QThreadPrivate::start (arg=0x105c3e560) at qthread_unix.cpp:307
      #22 0x00007fff8fd228bf in _pthread_start ()
      #23 0x00007fff8fd25b75 in thread_start ()

      It would be good if the qtbase network tests exercised the proxy stuff so that this error would be caught by the qtbase CI.

      Attachments

        No reviews matched the request. Check your Options in the drop-down menu of this sections header.

        Activity

          People

            xcm Martin Petersson (Inactive)
            kenthans Kent Hansen (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews

                There are no open Gerrit changes