| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
There is a bug in CFSocket/CFRunLoopSource in OS X 10.7 which can lead to a deadlock
in CFRunLoopRemoveSource or CFRunLoopSourceInvalidate if the CFSocket manager thread
is concurrently calling CFSocketInvalidate as a result of the socket's file descriptor
having been closed.
QLocalServer::close() triggers this race by closing the socket fd before unregistering
the QSocketNotifier, which internally uses CFSocket.
This commit fixes the problem by changing the ordering in close() so that the socket notifier
is disabled before closing the file descriptor. This change also makes QLocalServer::close()
perform operations in reverse order to QLocalServer::listen(), as would be expected.
Task-number: QTBUG-22789
Merge-request: 1470
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The Proxy-Connection header is a non standard header, but is widely
used so forming a de-facto standard.
Some proxies use the official Connection header, so we should check
for that in responses. Otherwise https connections over http proxy
fail in case the proxy sends "Connection: close" with the 407 reply.
Task-number: QTBUG-22177
Change-Id: If6cfa4ebb7ac9d97d65b6ddcc8257aee20ac0448
Reviewed-by: Peter Hartmann <peter.hartmann@nokia.com>
(cherry picked from commit 0ad18e18d1223b173d4a0d374b70ec08c3b22b11)
|
|
|
|
|
|
|
| |
Timer created when a socket is being used synchronously was not being
closed on destruction of the socket engine.
Reviewed-by: mread
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The writes >16k blocking in the emulator only applies to the winsock
connectivity used in S60 SDKs. It doesn't affect the ethernet
connectivity used by platform environments.
Restarting notifier after error seems like the correct thing to do,
and isn't causing any problems.
The duplicated code for setting error strings is unfortunate, but a
consequence of our decision not to derive from the native socket engine.
If symbian ever gets a Qt5 port, we should revisit it there.
Task-number: QTBUG-18371
Reviewed-by: Markus Goetz
|
|\
| |
| |
| |
| |
| |
| | |
master-integration
* 'master' of scm.dev.nokia.troll.no:qt/qt-earth-staging:
symbian socket engine: resolve some fixme and todo items
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Should be no behaviour changes from this commit, one function is renamed
and otherwise it is comment changes. (stuff we were unsure about when
creating the code initially but have decided to keep)
Multicast is not fully supported by symbian, and out of scope for the
QTBUG-7274 task. So the two stub functions are left with the ### comment
for the benefit of a future implementor.
Task-number: QTBUG-18371
Reviewed-by: Markus Goetz
|
|\ \
| |/
|/|
| |
| |
| |
| |
| |
| |
| | |
Conflicts:
src/gui/text/qtextengine.cpp
src/gui/text/qtextengine_p.h
src/gui/text/qtextlayout.cpp
src/plugins/phonon/mmf/mmf.pro
src/plugins/s60/5_0/5_0.pro
tests/auto/qtextlayout/tst_qtextlayout.cpp
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
The application can normally control the amount of buffering of a
socket or QNetworkReply by using the setReadBufferSize API.
This allows the application to flow control the TCP connection, and
avoids out of memory errors when the data being downloaded is received
faster than the application can process it.
However when using a proxy, the proxy socket engine has an internal
socket which is used to communicate with the proxy server. It is not
visible to the user, and does not have awareness of the buffer size of
the external socket.
To solve this, we limit the internal sockets' buffer size to 64k bytes.
Under normal operation, the data is swiftly copied to the external
socket where the buffer can grow (or not) based on the application's
set value for read buffer size.
Task-number: QT-4966
Reviewed-by: Markus Goetz
|
| |\
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
4.7-integration
* '4.7' of scm.dev.nokia.troll.no:qt/oslo-staging-1:
Updating file with CRLF line endings for the updated header
Fix a regression in QList::mid()
update gitignore
remove -fno-stack-protector
Fix make confclean
Update licenseheader text in source files
|
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Updated version of LGPL and FDL licenseheaders.
Apply release phase licenseheaders for all source files.
Reviewed-by: Trust Me
|
| |/
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Some proxies can discriminate based on the User-Agent when sent a
CONNECT command for establishing a HTTPS connection.
With this change, if the User-Agent header is set in the QNetworkRequest
then it will be passed to the http socket engine for use in the connect
command sent to the proxy.
As before, "Mozilla/5.0" will be used by default when no user agent
has been set.
Task-number: QTBUG-17223
Reviewed-by: Markus Goetz
|
|\ \
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Conflicts:
doc/src/examples/wheel.qdoc
src/gui/util/qflickgesture.cpp
src/gui/util/qflickgesture_p.h
src/gui/util/qscroller.cpp
src/gui/util/qscroller.h
src/gui/util/qscroller_p.h
src/gui/util/qscrollerproperties.cpp
src/gui/util/qscrollerproperties.h
tests/auto/qscroller/tst_qscroller.cpp
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Regression was introduced by 8d4cd52b6981a4e6deea7fdb77f56e40c4f3e6ba
when it failed to check when msecs == -1. This manifested visibly in KDE
failing to connect to any SSL site -- kioslaves are synchronous and use
waitForXXX(-1) (in this particular case, waitForEncrypted, which calls
waitForReadyRead).
Also, take the opportunity to convert these tests in QTcpSocket to use
port 80 (a defined service in the test server) instead of port 22.
Reviewed-by: Martin Petersson
|
|/ /
| |
| |
| |
| |
| |
| | |
Updated version of LGPL and FDL licenseheaders.
Apply release phase licenseheaders for all source files.
Reviewed-by: Trust Me
|
|\ \ |
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
QAbstractSocketEngine::createSocketEngine can return 0 as well as throw.
In two cases the pointer was being used before the null check, in a 3rd
case the null check was missing.
Reviewed-by: Markus Goetz
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Some proxies can discriminate based on the User-Agent when sent a
CONNECT command for establishing a HTTPS connection.
With this change, if the User-Agent header is set in the QNetworkRequest
then it will be passed to the http socket engine for use in the connect
command sent to the proxy.
As before, "Mozilla/5.0" will be used by default when no user agent
has been set.
Task-number: QTBUG-17223
Reviewed-by: Markus Goetz
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
In Symbian, the OS function to get the size of a pending datagram also
includes the size of the packet header (which is different for IPv4 and
IPv6). We were reading the datagram with the "peek" flag set to
implement pendingDatagramSize, then reading again normally when the
client called read/readDatagram.
This change removes the "peek" flag, and buffers the datagram in the
socket engine, returning it and clearing the buffer when read or
readDatagram is called.
If there is no buffered data, the existing code path is followed - it
isn't mandatory to call pendingDatagramSize before reading from the
socket.
Reviewed-by: Markus Goetz
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
When socks socket engine calls the write function of the native socket
engine, it now propagates errors to the abstract socket.
Task-number: QTBUG-18713
Reviewed-by: Markus Goetz
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
The generic layer calls setReadNotificationEnabled(false) on sockets
after they are closed. This no longer causes a warning from the symbian
socket engine. A warning will only be emitted if trying to enable
notifications on a closed socket.
Task-number: QTBUG-18713
Reviewed-by: Markus Goetz
|
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Make sure that waitForReadyRead times out if the read buffer is full.
Task-number: QTBUG-16123
Reviewed-by: Peter Hartmann
|
|\ \ \
| |/ /
| | |
| | |
| | |
| | |
| | |
| | | |
Conflicts:
configure.exe
src/s60installs/bwins/QtCoreu.def
src/s60installs/bwins/QtGuiu.def
src/s60installs/eabi/QtCoreu.def
|
| |\ \
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
symbian-socket-engine
Conflicts:
src/s60installs/bwins/QtCoreu.def
src/s60installs/bwins/QtGuiu.def
src/s60installs/bwins/QtNetworku.def
src/s60installs/eabi/QtCoreu.def
src/s60installs/eabi/QtGuiu.def
src/s60installs/eabi/QtNetworku.def
src/s60installs/eabi/QtOpenVGu.def
tests/auto/qabstractnetworkcache/tst_qabstractnetworkcache.cpp
|
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
If there is no event loop when a socket notification is enabled,
then invoke the method via a queued connection so that it is run
again when the event loop is started.
This covers sockets created and having an asynchronous API called
before calling QCoreApplication::exec().
Reviewed-by: Markus Goetz
|
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
When an IP6 address contains a valid IP4 address, report the address
in IP4 format (this is needed for SOCKS5 socket engine)
When binding Any or AnyIPv6, create a dual mode socket (KAfUnspec),
but report the local address as being the same as what the user
requested. (by default, symbian returns ::0 for the dual mode socket,
which causes problems for SOCKS and UDP code)
The intent is that most applications written for IP4 can work
transparently in an IP6 environment.
QTcpServer or QUdpSocket can accept either IP4 or IP6 from the same
socket.
Reviewed-by: Markus Goetz
|
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
Although symbian's multicast support is incomplete, this is enough to
pass the QUdpSocket test case. (no IGMP/MLD support in the OS)
Reviewed-by: Markus Goetz
|
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
An IPv6 socket can send to IPv4 addresses when in a dual mode stack.
On symbian, autobinded sockets have the ::0 local address rather than
0.0.0.0 - this check was causing the socket to be destroyed and recreated
with every call to writeDatagram.
Reviewed-by: Markus Goetz
|
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
A timer of 0ms completes on the next kernel tick (up to 0.999ms)
There is a poll GetOpt we can use instead that doesn't require using
a timer to cancel the select ioctl.
Reviewed-by: Markus Goetz
|
| |\ \ \
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
Conflicts:
src/network/access/qhttpnetworkconnectionchannel.cpp
src/network/socket/qlocalsocket.cpp
src/s60installs/bwins/QtCoreu.def
src/s60installs/bwins/QtGuiu.def
src/s60installs/bwins/QtTestu.def
src/s60installs/eabi/QtCoreu.def
src/s60installs/eabi/QtGuiu.def
|
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
When testing the socks5 socket engine, it closes the socket from
within _q_controlSocketError. Frequently a data abort occurs after this
when printing the debug message.
Moved the debug message before emitting the signal to avoid this.
Reviewed-by: Markus Goetz
|
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
Sometimes the error is in the return code from the ioctl, other times
it is in the select last error getopt. Treat both error sources the
same way and call setError. Return code has higher priority.
Reviewed-by: Markus Goetz
|
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
Private API, QHostInfoPrivate::fromName, which is called from
QAbstractSocket when the network session property is set.
Reviewed-by: Markus Goetz
|
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
As the symbian socket engine is driven by an active object in the
QtNetwork dll, this needs to hook into the event dispatcher in the
QtCore dll.
The QActiveObject base class is now a private export from QtCore
The method of deferring socket events now works with any kind of
QActiveObject, and not only the QSocketActiveObject (which handles
"open C" sockets)
The base class has a new function, to check if socket events are blocked.
If so, it adds the active object to the deferred queue.
The derived class should return from it's RunL in this case, which will
be called again later. (same usage as the maybeQueueForLater function)
reactivateAndComplete function in the event dispatcher is changed to
complete the active object again with the same status code as originally.
Previously it always used KErrNone, which is not ok for QAsyncSelect as
it needs to check the error code from the asynchronous call.
Reviewed-by: Markus Goetz
Reviewed-by: mread
|
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
Added a mutex to QNetworkSessionPrivate
Lock the mutex in the symbian bearer plugin for functions that change
the validity of the RConnection.
Added factory functions to open an RSocket or RHostResolver, which lock
the mutex before the esock function calls. If there is no RConnection,
then KErrNotReady is returned (the same as when there is an RConnection
but it has not been started).
Task-number: QTBUG-18143
Reviewed-by: Markus Goetz
|
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
Instead of creating socket notifiers and sending faked events to them,
call the engine's notification functions directly.
Reviewed-by: Markus Goetz
|
| | | | | |
|
| | | | | |
|
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
In the unix socket engine, EADDRNOTAVAIL is returned by the native call
when attempting to bind to a non existant interface. On symbian, the
generic KErrNotFound is returned.
Specifically for bind() convert KErrNotFound to the expected error code
QAbstractSocket::SocketAddressNotAvailableError which is relied on by
autotest (and possibly but unlikely, existing applications)
Reviewed-by: Markus Goetz
|
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
The proxy socket engines forward the network session to the "real" socket
they use natively.
Reviewed-by: Markus Goetz
|
| | | | |
| | | | |
| | | | |
| | | | | |
Reviewed-by: Markus Goetz
|
| | | | |
| | | | |
| | | | |
| | | | | |
Reviewed-by: Markus Goetz
|
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
RTimer is only usable in the thread it was created.
Reviewed-by: Markus Goetz
|
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
The http socket engine was hiding errors other than RemoteHostClosedError.
This caused problems, because for other errors, the low level socket is
still closed in the native socket engine. By not emitting the read
notification, the error was never informed to QAbstractSocket and as a
result, the application never gets the disconnected signal.
Reviewed-by: Martin Petersson
|
| |\ \ \ \
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | | |
scm.dev.troll.no:qt/qt-symbian-network into symbian-socket-engine
Conflicts:
src/network/access/qnetworkaccessmanager.cpp
tests/auto/qsslsocket/tst_qsslsocket.cpp
|
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | | |
Symbian workarounds are better in the symbian socket engine than
generic layer, where this is possible.
Reviewed-by: Markus Goetz
|
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | | |
When starting a connection implicitly, datagrams fail with KErrWouldBlock
on S60 5.0 and earlier. On symbian 3, they are dropped without error, but
the bytes written is set to 0.
Due to an apparent bug in symbian, the first packet is failed/dropped on
a UDP socket even if the bearer is up due to existing TCP connection.
With blocking sockets or explicit RConnection usage, this doesn't happen.
Reviewed-by: Markus Goetz
|
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | | |
qtcpsocket autotest checks for a specific error
Reviewed-by: Markus Goetz
|
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | | |
This ensures the specified QNetworkSession from the QNetworkAccessManager
is used to route the packets, when using a SOCKS proxy.
Reviewed-by: Markus Goetz
|
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | | |
Symbian API RecvOneOrMore only supports stream oriented sockets.
So for UDP we use RecvFrom instead and discard the source address.
Reviewed-by: Markus Goetz
|
| | | | | |
| | | | | |
| | | | | |
| | | | | | |
Reviewed-by: Markus Goetz
|