summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--src/network/access/qhttpnetworkreply.cpp2
-rw-r--r--src/network/access/qnetworkcookie.h2
-rw-r--r--src/network/access/qnetworkrequest.h2
-rw-r--r--src/network/kernel/qnetworkinterface.cpp6
-rw-r--r--src/network/kernel/qnetworkinterface_symbian.cpp70
-rw-r--r--src/network/network.pro1
-rw-r--r--src/network/socket/qlocalserver_unix.cpp10
-rw-r--r--src/network/socket/qlocalsocket_unix.cpp14
-rw-r--r--src/network/socket/qnativesocketengine.cpp8
-rw-r--r--src/network/socket/qnativesocketengine_p.h4
-rw-r--r--src/network/socket/qnativesocketengine_unix.cpp102
-rw-r--r--src/network/socket/qudpsocket.cpp16
-rw-r--r--src/network/ssl/qsslsocket_openssl_symbols.cpp4
-rw-r--r--src/network/ssl/ssl.pri4
14 files changed, 122 insertions, 123 deletions
diff --git a/src/network/access/qhttpnetworkreply.cpp b/src/network/access/qhttpnetworkreply.cpp
index ef4a865..5319252 100644
--- a/src/network/access/qhttpnetworkreply.cpp
+++ b/src/network/access/qhttpnetworkreply.cpp
@@ -550,7 +550,7 @@ bool QHttpNetworkReplyPrivate::connectionCloseEnabled()
// note this function can only be used for non-chunked, non-compressed with
// known content length
qint64 QHttpNetworkReplyPrivate::readBodyFast(QAbstractSocket *socket, QRingBuffer *rb)
-{
+{
quint64 toBeRead = qMin(socket->bytesAvailable(), bodyLength - contentRead);
char* dst = rb->reserve(toBeRead);
qint64 haveRead = socket->read(dst, toBeRead);
diff --git a/src/network/access/qnetworkcookie.h b/src/network/access/qnetworkcookie.h
index c5f03fb..1bae7ae 100644
--- a/src/network/access/qnetworkcookie.h
+++ b/src/network/access/qnetworkcookie.h
@@ -67,7 +67,7 @@ public:
Full
};
- QNetworkCookie();
+ QNetworkCookie();
QNetworkCookie(const QByteArray &name );
QNetworkCookie(const QByteArray &name, const QByteArray &value );
QNetworkCookie(const QNetworkCookie &other);
diff --git a/src/network/access/qnetworkrequest.h b/src/network/access/qnetworkrequest.h
index a53aed3..cf06f7c 100644
--- a/src/network/access/qnetworkrequest.h
+++ b/src/network/access/qnetworkrequest.h
@@ -89,7 +89,7 @@ public:
explicit QNetworkRequest();
- explicit QNetworkRequest(const QUrl &url);
+ explicit QNetworkRequest(const QUrl &url);
QNetworkRequest(const QNetworkRequest &other);
~QNetworkRequest();
QNetworkRequest &operator=(const QNetworkRequest &other);
diff --git a/src/network/kernel/qnetworkinterface.cpp b/src/network/kernel/qnetworkinterface.cpp
index 953722c..e588c18 100644
--- a/src/network/kernel/qnetworkinterface.cpp
+++ b/src/network/kernel/qnetworkinterface.cpp
@@ -128,7 +128,7 @@ QString QNetworkInterfacePrivate::makeHwAddress(int len, uchar *data)
for (int i = 0; i < len; ++i) {
if (i)
result += QLatin1Char(':');
-
+
char buf[3];
#if defined(Q_OS_WIN) && !defined(Q_OS_WINCE) && defined(_MSC_VER) && _MSC_VER >= 1400
sprintf_s(buf, 3, "%02hX", ushort(data[i]));
@@ -603,13 +603,13 @@ QDebug operator<<(QDebug debug, const QNetworkInterface &networkInterface)
<< ", hardware address = " << networkInterface.hardwareAddress()
<< ", flags = ";
flagsDebug(debug, networkInterface.flags());
-#if defined(Q_CC_RVCT)
+#if defined(Q_CC_RVCT)
// RVCT gets confused with << networkInterface.addressEntries(), reason unknown.
debug.nospace() << ")\n";
#else
debug.nospace() << ", entries = " << networkInterface.addressEntries()
<< ")\n";
-#endif
+#endif
return debug.space();
}
#endif
diff --git a/src/network/kernel/qnetworkinterface_symbian.cpp b/src/network/kernel/qnetworkinterface_symbian.cpp
index d3aafa3..bec2dc3 100644
--- a/src/network/kernel/qnetworkinterface_symbian.cpp
+++ b/src/network/kernel/qnetworkinterface_symbian.cpp
@@ -69,14 +69,14 @@ static QNetworkInterface::InterfaceFlags convertFlags( const TSoInetInterfaceInf
flags |= (aInfo.iState == EIfUp) ? QNetworkInterface::IsUp : QNetworkInterface::InterfaceFlag(0);
// We do not have separate flag for running in Symbian OS
flags |= (aInfo.iState == EIfUp) ? QNetworkInterface::IsRunning : QNetworkInterface::InterfaceFlag(0);
- flags |= (aInfo.iFeatures&KIfCanBroadcast) ? QNetworkInterface::CanBroadcast : QNetworkInterface::InterfaceFlag(0);
+ flags |= (aInfo.iFeatures&KIfCanBroadcast) ? QNetworkInterface::CanBroadcast : QNetworkInterface::InterfaceFlag(0);
flags |= (aInfo.iFeatures&KIfIsLoopback) ? QNetworkInterface::IsLoopBack : QNetworkInterface::InterfaceFlag(0);
flags |= (aInfo.iFeatures&KIfIsPointToPoint) ? QNetworkInterface::IsPointToPoint : QNetworkInterface::InterfaceFlag(0);
flags |= (aInfo.iFeatures&KIfCanMulticast) ? QNetworkInterface::CanMulticast : QNetworkInterface::InterfaceFlag(0);
return flags;
}
-QString qstringFromDesc( const TDesC& aData )
+QString qstringFromDesc( const TDesC& aData )
{
return QString::fromUtf16(aData.Ptr(), aData.Length());
}
@@ -85,20 +85,20 @@ static QList<QNetworkInterfacePrivate *> interfaceListing()
{
TInt err( KErrNone );
QList<QNetworkInterfacePrivate *> interfaces;
-
+
// Connect to Native socket server
RSocketServ socketServ;
err = socketServ.Connect();
if( err )
return interfaces;
-
+
// Open dummy socket for interface queries
RSocket socket;
err = socket.Open( socketServ, _L("udp"));
if( err )
{
socketServ.Close();
- return interfaces;
+ return interfaces;
}
// Ask socket to start enumerating interfaces
@@ -107,8 +107,8 @@ static QList<QNetworkInterfacePrivate *> interfaceListing()
{
socket.Close();
socketServ.Close();
- return interfaces;
- }
+ return interfaces;
+ }
int ifindex = 0;
TPckgBuf<TSoInetInterfaceInfo> infoPckg;
@@ -118,74 +118,74 @@ static QList<QNetworkInterfacePrivate *> interfaceListing()
// Do not include IPv6 addresses because netmask and broadcast address cannot be determined correctly
if( info.iName != KNullDesC && info.iAddress.IsV4Mapped() )
{
- TName address;
- QNetworkAddressEntry entry;
- QNetworkInterfacePrivate *iface = 0;
-
- iface = new QNetworkInterfacePrivate;
+ TName address;
+ QNetworkAddressEntry entry;
+ QNetworkInterfacePrivate *iface = 0;
+
+ iface = new QNetworkInterfacePrivate;
iface->index = ifindex++;
interfaces << iface;
iface->name = qstringFromDesc( info.iName );
iface->flags = convertFlags( info );
-
+
if( /*info.iFeatures&KIfHasHardwareAddr &&*/ info.iHwAddr.Family() != KAFUnspec )
{
- for ( TInt i = sizeof(SSockAddr); i < sizeof(SSockAddr) + info.iHwAddr.GetUserLen(); i++ )
+ for ( TInt i = sizeof(SSockAddr); i < sizeof(SSockAddr) + info.iHwAddr.GetUserLen(); i++ )
{
address.AppendNumFixedWidth(info.iHwAddr[i], EHex, 2);
if( ( i + 1) < sizeof(SSockAddr) + info.iHwAddr.GetUserLen() )
address.Append( _L(":") );
- }
- address.UpperCase();
+ }
+ address.UpperCase();
iface->hardwareAddress = qstringFromDesc( address );
}
-
+
// Get the address of the interface
info.iAddress.Output(address);
- entry.setIp( QHostAddress( qstringFromDesc( address ) ) );
+ entry.setIp( QHostAddress( qstringFromDesc( address ) ) );
- // Get the interface netmask
- // TODO: For some reason netmask is always 0.0.0.0
+ // Get the interface netmask
+ // TODO: For some reason netmask is always 0.0.0.0
//info.iNetMask.Output(address);
- //entry.setNetmask( QHostAddress( qstringFromDesc( address ) ) );
-
+ //entry.setNetmask( QHostAddress( qstringFromDesc( address ) ) );
+
// Workaround: Let Symbian determine netmask based on IP address class
// TODO: works only for IPv4
TInetAddr netmask;
netmask.NetMask( info.iAddress );
netmask.Output(address);
- entry.setNetmask( QHostAddress( qstringFromDesc( address ) ) );
-
+ entry.setNetmask( QHostAddress( qstringFromDesc( address ) ) );
+
// Get the interface broadcast address
- if (iface->flags & QNetworkInterface::CanBroadcast)
+ if (iface->flags & QNetworkInterface::CanBroadcast)
{
// For some reason broadcast address is always 0.0.0.0
// info.iBrdAddr.Output(address);
- // entry.setBroadcast( QHostAddress( qstringFromDesc( address ) ) );
-
+ // entry.setBroadcast( QHostAddress( qstringFromDesc( address ) ) );
+
// Workaround: Let Symbian determine broadcast address based on IP address
// TODO: works only for IPv4
TInetAddr broadcast;
- broadcast.NetBroadcast( info.iAddress );
+ broadcast.NetBroadcast( info.iAddress );
broadcast.Output(address);
entry.setBroadcast( QHostAddress( qstringFromDesc( address ) ) );
}
-
+
// Add new entry to interface address entries
- iface->addressEntries << entry;
-
-#if defined(QNETWORKINTERFACE_DEBUG)
+ iface->addressEntries << entry;
+
+#if defined(QNETWORKINTERFACE_DEBUG)
printf("\n Found network interface %s, interface flags:\n\
IsUp = %d, IsRunning = %d, CanBroadcast = %d,\n\
IsLoopBack = %d, IsPointToPoint = %d, CanMulticast = %d, \n\
ip = %s, netmask = %s, broadcast = %s,\n\
- hwaddress = %s",
+ hwaddress = %s",
iface->name.toLatin1().constData(),
iface->flags & QNetworkInterface::IsUp, iface->flags & QNetworkInterface::IsRunning, iface->flags & QNetworkInterface::CanBroadcast,
iface->flags & QNetworkInterface::IsLoopBack, iface->flags & QNetworkInterface::IsPointToPoint, iface->flags & QNetworkInterface::CanMulticast,
entry.ip().toString().toLatin1().constData(), entry.netmask().toString().toLatin1().constData(), entry.broadcast().toString().toLatin1().constData(),
- iface->hardwareAddress.toLatin1().constData());
-#endif
+ iface->hardwareAddress.toLatin1().constData());
+#endif
}
}
diff --git a/src/network/network.pro b/src/network/network.pro
index 59cffd0..e890b94 100644
--- a/src/network/network.pro
+++ b/src/network/network.pro
@@ -28,4 +28,3 @@ symbian {
TARGET.UID3=0x2001B2DE
LIBS += -lesock -linsock
}
-
diff --git a/src/network/socket/qlocalserver_unix.cpp b/src/network/socket/qlocalserver_unix.cpp
index e4bc1aa..b05a2cc 100644
--- a/src/network/socket/qlocalserver_unix.cpp
+++ b/src/network/socket/qlocalserver_unix.cpp
@@ -112,7 +112,7 @@ bool QLocalServerPrivate::listen(const QString &requestedServerName)
//
// As an workaround, we set the socket to non blocking so possible
// subsequent call to accept will not block in any case
- //
+ //
// This change can be removed once more generic fix to select thread
// syncronization problem is implemented.
int flags = fcntl(listenSocket, F_GETFL, 0);
@@ -120,10 +120,10 @@ bool QLocalServerPrivate::listen(const QString &requestedServerName)
|| -1 == (fcntl(listenSocket, F_SETFL, flags | O_NONBLOCK))) {
setError(QLatin1String("QLocalServer::listen"));
closeServer();
- return false;
- }
-#endif
-
+ return false;
+ }
+#endif
+
// bind
if(-1 == qBind(listenSocket, (sockaddr *)&addr, sizeof(sockaddr_un))) {
setError(QLatin1String("QLocalServer::listen"));
diff --git a/src/network/socket/qlocalsocket_unix.cpp b/src/network/socket/qlocalsocket_unix.cpp
index cba5a7f..b2eb15f 100644
--- a/src/network/socket/qlocalsocket_unix.cpp
+++ b/src/network/socket/qlocalsocket_unix.cpp
@@ -301,7 +301,7 @@ void QLocalSocketPrivate::_q_connectToSocket()
case ETIMEDOUT:
errorOccurred(QLocalSocket::SocketTimeoutError, function);
break;
- case EINPROGRESS:
+ case EINPROGRESS:
case EAGAIN:
// Try again later, all of the sockets listening are full
if (!delayConnect) {
@@ -534,14 +534,14 @@ bool QLocalSocket::waitForConnected(int msec)
timer.start();
while (state() == ConnectingState
&& (-1 == msec || timer.elapsed() < msec)) {
-#ifdef Q_OS_SYMBIAN
- // On Symbian, ready-to-write is signaled when non-blocking socket
- // connect is finised. Is ready-to-read really used on other
- // UNIX paltforms when using non-blocking AF_UNIX socket?
+#ifdef Q_OS_SYMBIAN
+ // On Symbian, ready-to-write is signaled when non-blocking socket
+ // connect is finised. Is ready-to-read really used on other
+ // UNIX paltforms when using non-blocking AF_UNIX socket?
result = ::select(d->connectingSocket + 1, 0, &fds, 0, &timeout);
#else
- result = ::select(d->connectingSocket + 1, &fds, 0, 0, &timeout);
-#endif
+ result = ::select(d->connectingSocket + 1, &fds, 0, 0, &timeout);
+#endif
if (-1 == result && errno != EINTR) {
d->errorOccurred( QLocalSocket::UnknownSocketError,
QLatin1String("QLocalSocket::waitForConnected"));
diff --git a/src/network/socket/qnativesocketengine.cpp b/src/network/socket/qnativesocketengine.cpp
index 666c86e..f88094a 100644
--- a/src/network/socket/qnativesocketengine.cpp
+++ b/src/network/socket/qnativesocketengine.cpp
@@ -381,13 +381,13 @@ bool QNativeSocketEngine::initialize(QAbstractSocket::SocketType socketType, QAb
return false;
}
-
+
// Make sure we receive out-of-band data
// On Symbian OS this works only with native IP stack, not with WinSock
if (socketType == QAbstractSocket::TcpSocket
&& !setOption(ReceiveOutOfBandData, 1)) {
qWarning("QNativeSocketEngine::initialize unable to inline out-of-band data");
- }
+ }
// Set the send and receive buffer sizes to a magic size, found
// most optimal for our platforms.
@@ -913,7 +913,7 @@ bool QNativeSocketEngine::waitForReadOrWrite(bool *readyToRead, bool *readyToWri
d_func()->fetchConnectionParameters();
return true;
}
-#endif
+#endif
if (ret == 0) {
if (timedOut)
*timedOut = true;
@@ -1094,7 +1094,7 @@ bool QExceptionNotifier::event(QEvent *e)
engine->exceptionNotification();
return true;
}
- return QSocketNotifier::event(e);
+ return QSocketNotifier::event(e);
}
void QNativeSocketEngine::setReadNotificationEnabled(bool enable)
diff --git a/src/network/socket/qnativesocketengine_p.h b/src/network/socket/qnativesocketengine_p.h
index a8d7fff..c2881b0 100644
--- a/src/network/socket/qnativesocketengine_p.h
+++ b/src/network/socket/qnativesocketengine_p.h
@@ -351,8 +351,8 @@ public:
struct sockaddr_storage aa;
#else
struct sockaddr_in aa;
-#endif
-
+#endif
+
QSocketNotifier *readNotifier, *writeNotifier, *exceptNotifier;
#ifdef Q_OS_WIN
diff --git a/src/network/socket/qnativesocketengine_unix.cpp b/src/network/socket/qnativesocketengine_unix.cpp
index 58adaff..0027c8e 100644
--- a/src/network/socket/qnativesocketengine_unix.cpp
+++ b/src/network/socket/qnativesocketengine_unix.cpp
@@ -281,7 +281,7 @@ bool QNativeSocketEnginePrivate::setOption(QNativeSocketEngine::SocketOption opt
}
case QNativeSocketEngine::AddressReusable:
#ifdef Q_OS_SYMBIAN
- n = SO_REUSEADDR;
+ n = SO_REUSEADDR;
#elif SO_REUSEPORT
n = SO_REUSEPORT;
#else
@@ -295,7 +295,7 @@ bool QNativeSocketEnginePrivate::setOption(QNativeSocketEngine::SocketOption opt
break;
}
- return qt_socket_setsockopt(socketDescriptor, SOL_SOCKET, n, (char *) &v, sizeof(v)) == 0;
+ return qt_socket_setsockopt(socketDescriptor, SOL_SOCKET, n, (char *) &v, sizeof(v)) == 0;
}
@@ -303,8 +303,8 @@ bool QNativeSocketEnginePrivate::nativeConnect(const QHostAddress &addr, quint16
{
#ifdef QNATIVESOCKETENGINE_DEBUG
qDebug("QNativeSocketEnginePrivate::nativeConnect() : %d ", socketDescriptor);
-#endif
-
+#endif
+
struct sockaddr_in sockAddrIPv4;
struct sockaddr *sockAddrPtr = 0;
QT_SOCKLEN_T sockAddrSize = 0;
@@ -571,7 +571,7 @@ bool QNativeSocketEnginePrivate::nativeHasPendingDatagrams() const
#ifdef Q_OS_SYMBIAN
qint64 QNativeSocketEnginePrivate::nativePendingDatagramSize() const
{
- size_t nbytes = 0;
+ size_t nbytes = 0;
qt_socket_ioctl(socketDescriptor, E32IONREAD, (char *) &nbytes);
return qint64(nbytes-28);
}
@@ -579,7 +579,7 @@ qint64 QNativeSocketEnginePrivate::nativePendingDatagramSize() const
qint64 QNativeSocketEnginePrivate::nativePendingDatagramSize() const
{
QVarLengthArray<char, 8192> udpMessagePeekBuffer(8192);
- ssize_t recvResult = -1;
+ ssize_t recvResult = -1;
for (;;) {
// the data written to udpMessagePeekBuffer is discarded, so
@@ -595,7 +595,7 @@ qint64 QNativeSocketEnginePrivate::nativePendingDatagramSize() const
udpMessagePeekBuffer.resize(udpMessagePeekBuffer.size() * 2);
}
-
+
#if defined (QNATIVESOCKETENGINE_DEBUG)
qDebug("QNativeSocketEnginePrivate::nativePendingDatagramSize() == %i", recvResult);
#endif
@@ -644,23 +644,23 @@ qint64 QNativeSocketEnginePrivate::nativeSendDatagram(const char *data, qint64 l
#if !defined(QT_NO_IPV6)
struct sockaddr_in6 sockAddrIPv6;
if (host.protocol() == QAbstractSocket::IPv6Protocol) {
- memset(&sockAddrIPv6, 0, sizeof(sockAddrIPv6));
- sockAddrIPv6.sin6_family = AF_INET6;
- sockAddrIPv6.sin6_port = htons(port);
-
- Q_IPV6ADDR tmp = host.toIPv6Address();
- memcpy(&sockAddrIPv6.sin6_addr.s6_addr, &tmp, sizeof(tmp));
- sockAddrSize = sizeof(sockAddrIPv6);
- sockAddrPtr = (struct sockaddr *)&sockAddrIPv6;
+ memset(&sockAddrIPv6, 0, sizeof(sockAddrIPv6));
+ sockAddrIPv6.sin6_family = AF_INET6;
+ sockAddrIPv6.sin6_port = htons(port);
+
+ Q_IPV6ADDR tmp = host.toIPv6Address();
+ memcpy(&sockAddrIPv6.sin6_addr.s6_addr, &tmp, sizeof(tmp));
+ sockAddrSize = sizeof(sockAddrIPv6);
+ sockAddrPtr = (struct sockaddr *)&sockAddrIPv6;
} else
#endif
if (host.protocol() == QAbstractSocket::IPv4Protocol) {
- memset(&sockAddrIPv4, 0, sizeof(sockAddrIPv4));
- sockAddrIPv4.sin_family = AF_INET;
- sockAddrIPv4.sin_port = htons(port);
- sockAddrIPv4.sin_addr.s_addr = htonl(host.toIPv4Address());
- sockAddrSize = sizeof(sockAddrIPv4);
- sockAddrPtr = (struct sockaddr *)&sockAddrIPv4;
+ memset(&sockAddrIPv4, 0, sizeof(sockAddrIPv4));
+ sockAddrIPv4.sin_family = AF_INET;
+ sockAddrIPv4.sin_port = htons(port);
+ sockAddrIPv4.sin_addr.s_addr = htonl(host.toIPv4Address());
+ sockAddrSize = sizeof(sockAddrIPv4);
+ sockAddrPtr = (struct sockaddr *)&sockAddrIPv4;
}
// ignore the SIGPIPE signal
@@ -870,10 +870,10 @@ int QNativeSocketEnginePrivate::nativeSelect(int timeout, bool selectForRead) co
tv.tv_sec = timeout / 1000;
tv.tv_usec = (timeout % 1000) * 1000;
-#ifdef Q_OS_SYMBIAN
+#ifdef Q_OS_SYMBIAN
fd_set fdexec;
FD_ZERO(&fdexec);
- FD_SET(socketDescriptor, &fdexec);
+ FD_SET(socketDescriptor, &fdexec);
#endif
QTime timer;
@@ -884,18 +884,18 @@ int QNativeSocketEnginePrivate::nativeSelect(int timeout, bool selectForRead) co
if (selectForRead)
#ifndef Q_OS_SYMBIAN
retval = qt_socket_select(socketDescriptor + 1, &fds, 0, 0, timeout < 0 ? 0 : &tv);
-#else
- retval = qt_socket_select(socketDescriptor + 1, &fds, 0, &fdexec, timeout < 0 ? 0 : &tv);
-#endif
+#else
+ retval = qt_socket_select(socketDescriptor + 1, &fds, 0, &fdexec, timeout < 0 ? 0 : &tv);
+#endif
else
#ifndef Q_OS_SYMBIAN
retval = qt_socket_select(socketDescriptor + 1, 0, &fds, 0, timeout < 0 ? 0 : &tv);
-#else
- retval = qt_socket_select(socketDescriptor + 1, 0, &fds, &fdexec, timeout < 0 ? 0 : &tv);
-#endif
+#else
+ retval = qt_socket_select(socketDescriptor + 1, 0, &fds, &fdexec, timeout < 0 ? 0 : &tv);
+#endif
+
-
-#ifdef Q_OS_SYMBIAN
+#ifdef Q_OS_SYMBIAN
bool selectForExec = false;
if(retval != 0) {
if(retval < 0) {
@@ -904,10 +904,10 @@ int QNativeSocketEnginePrivate::nativeSelect(int timeout, bool selectForRead) co
selectForExec = FD_ISSET(socketDescriptor, &fdexec);
}
if(selectForExec) {
- qWarning("nativeSelect (selectForRead %d, retVal %d, errno %d) Unexpected expectfds ready in fd %d",
- selectForRead, retval, errno, socketDescriptor);
- }
-#endif
+ qWarning("nativeSelect (selectForRead %d, retVal %d, errno %d) Unexpected expectfds ready in fd %d",
+ selectForRead, retval, errno, socketDescriptor);
+ }
+#endif
if (retval != -1 || errno != EINTR) {
break;
@@ -931,7 +931,7 @@ int QNativeSocketEnginePrivate::nativeSelect(int timeout, bool selectForRead) co
}
int QNativeSocketEnginePrivate::nativeSelect(int timeout, bool checkRead, bool checkWrite,
- bool *selectForRead, bool *selectForWrite) const
+ bool *selectForRead, bool *selectForWrite) const
{
fd_set fdread;
FD_ZERO(&fdread);
@@ -942,12 +942,12 @@ int QNativeSocketEnginePrivate::nativeSelect(int timeout, bool checkRead, bool c
FD_ZERO(&fdwrite);
if (checkWrite)
FD_SET(socketDescriptor, &fdwrite);
-
-#ifdef Q_OS_SYMBIAN
+
+#ifdef Q_OS_SYMBIAN
fd_set fdexec;
FD_ZERO(&fdexec);
- FD_SET(socketDescriptor, &fdexec);
-#endif
+ FD_SET(socketDescriptor, &fdexec);
+#endif
struct timeval tv;
tv.tv_sec = timeout / 1000;
@@ -960,7 +960,7 @@ int QNativeSocketEnginePrivate::nativeSelect(int timeout, bool checkRead, bool c
do {
#ifndef Q_OS_SYMBIAN
ret = qt_socket_select(socketDescriptor + 1, &fdread, &fdwrite, 0, timeout < 0 ? 0 : &tv);
-#else
+#else
ret = qt_socket_select(socketDescriptor + 1, &fdread, &fdwrite, &fdexec, timeout < 0 ? 0 : &tv);
bool selectForExec = false;
if(ret != 0) {
@@ -970,18 +970,18 @@ int QNativeSocketEnginePrivate::nativeSelect(int timeout, bool checkRead, bool c
selectForExec = FD_ISSET(socketDescriptor, &fdexec);
}
if(selectForExec) {
- qWarning("nativeSelect (checkRead %d, checkWrite %d, ret %d, errno %d): Unexpected expectfds ready in fd %d",
- checkRead, checkWrite, ret, errno, socketDescriptor);
- if (checkRead)
- FD_SET(socketDescriptor, &fdread);
- if (checkWrite)
- FD_SET(socketDescriptor, &fdwrite);
-
- if ((ret == -1) && ( errno == ECONNREFUSED || errno == EPIPE ))
+ qWarning("nativeSelect (checkRead %d, checkWrite %d, ret %d, errno %d): Unexpected expectfds ready in fd %d",
+ checkRead, checkWrite, ret, errno, socketDescriptor);
+ if (checkRead)
+ FD_SET(socketDescriptor, &fdread);
+ if (checkWrite)
+ FD_SET(socketDescriptor, &fdwrite);
+
+ if ((ret == -1) && ( errno == ECONNREFUSED || errno == EPIPE ))
ret = 1;
-
+
}
-#endif
+#endif
if (ret != -1 || errno != EINTR) {
break;
}
diff --git a/src/network/socket/qudpsocket.cpp b/src/network/socket/qudpsocket.cpp
index 61b28ba..8e641d9 100644
--- a/src/network/socket/qudpsocket.cpp
+++ b/src/network/socket/qudpsocket.cpp
@@ -91,12 +91,12 @@
This enum describes the different flags you can pass to modify the
behavior of QUdpSocket::bind().
-
+
\note On Symbian OS bind flags behaviour depends on process capabilties.
- If process has NetworkControl capability, the bind attempt with
+ If process has NetworkControl capability, the bind attempt with
ReuseAddressHint will always succeed even the address and port is already
- bound by another socket with any flags. If process does not have
- NetworkControl capability, the bind attempt to address and port already
+ bound by another socket with any flags. If process does not have
+ NetworkControl capability, the bind attempt to address and port already
bound by another socket will always fail.
\value ShareAddress Allow other services to bind to the same address
@@ -353,7 +353,7 @@ qint64 QUdpSocket::pendingDatagramSize() const
as even if they are sent successfully, they are likely to be
fragmented by the IP layer before arriving at their final
destination.
-
+
\warning In S60 5.0 and earlier versions, the writeDatagram return
value is not reliable for large datagrams.
@@ -383,8 +383,8 @@ qint64 QUdpSocket::writeDatagram(const char *data, qint64 size, const QHostAddre
// As an workaround, we just set sent = size
if( sent == 0 )
sent = size;
- }
-#endif
+ }
+#endif
d->cachedSocketDescriptor = d->socketEngine->socketDescriptor();
if (sent >= 0) {
@@ -397,7 +397,7 @@ qint64 QUdpSocket::writeDatagram(const char *data, qint64 size, const QHostAddre
return sent;
}
-/*!
+/*!
\fn qint64 QUdpSocket::writeDatagram(const QByteArray &datagram,
const QHostAddress &host, quint16 port)
\overload
diff --git a/src/network/ssl/qsslsocket_openssl_symbols.cpp b/src/network/ssl/qsslsocket_openssl_symbols.cpp
index 6b777e3..2199a58 100644
--- a/src/network/ssl/qsslsocket_openssl_symbols.cpp
+++ b/src/network/ssl/qsslsocket_openssl_symbols.cpp
@@ -602,7 +602,7 @@ bool q_resolveOpenSslSymbols()
RESOLVEFUNC(d2i_RSAPrivateKey, 2296, libs.second )
#endif
RESOLVEFUNC(OPENSSL_add_all_algorithms_noconf, 1153, libs.second )
- RESOLVEFUNC(OPENSSL_add_all_algorithms_conf, 1152, libs.second )
+ RESOLVEFUNC(OPENSSL_add_all_algorithms_conf, 1152, libs.second )
#else // Q_OS_SYMBIAN
#ifdef SSLEAY_MACROS
RESOLVEFUNC(ASN1_dup)
@@ -723,7 +723,7 @@ bool q_resolveOpenSslSymbols()
#endif
RESOLVEFUNC(OPENSSL_add_all_algorithms_noconf)
RESOLVEFUNC(OPENSSL_add_all_algorithms_conf)
-#endif // Q_OS_SYMBIAN
+#endif // Q_OS_SYMBIAN
symbolsResolved = true;
delete libs.first;
delete libs.second;
diff --git a/src/network/ssl/ssl.pri b/src/network/ssl/ssl.pri
index 6021d5d..d07f406 100644
--- a/src/network/ssl/ssl.pri
+++ b/src/network/ssl/ssl.pri
@@ -1,11 +1,11 @@
# OpenSSL support; compile in QSslSocket.
contains(QT_CONFIG, openssl) | contains(QT_CONFIG, openssl-linked) {
-
+
symbian {
INCLUDEPATH *= $$OS_LAYER_SSL_SYSTEMINCLUDE
} else {
- include($$QT_SOURCE_TREE/config.tests/unix/openssl/openssl.pri)
+ include($$QT_SOURCE_TREE/config.tests/unix/openssl/openssl.pri)
}
HEADERS += ssl/qssl.h \