summaryrefslogtreecommitdiffstats
path: root/kdecore/network
diff options
context:
space:
mode:
Diffstat (limited to 'kdecore/network')
-rw-r--r--kdecore/network/kbufferedsocket.cpp16
-rw-r--r--kdecore/network/kbufferedsocket.h8
-rw-r--r--kdecore/network/kclientsocketbase.cpp16
-rw-r--r--kdecore/network/kclientsocketbase.h8
-rw-r--r--kdecore/network/kdatagramsocket.cpp8
-rw-r--r--kdecore/network/kdatagramsocket.h4
-rw-r--r--kdecore/network/khttpproxysocketdevice.cpp6
-rw-r--r--kdecore/network/ksocketbase.cpp4
-rw-r--r--kdecore/network/ksocketbase.h8
-rw-r--r--kdecore/network/ksocketbuffer.cpp4
-rw-r--r--kdecore/network/ksocketdevice.cpp10
-rw-r--r--kdecore/network/ksocketdevice.h8
-rw-r--r--kdecore/network/ksockssocketdevice.cpp10
-rw-r--r--kdecore/network/ksockssocketdevice.h8
14 files changed, 59 insertions, 59 deletions
diff --git a/kdecore/network/kbufferedsocket.cpp b/kdecore/network/kbufferedsocket.cpp
index 85b433193..ffac2e98b 100644
--- a/kdecore/network/kbufferedsocket.cpp
+++ b/kdecore/network/kbufferedsocket.cpp
@@ -118,7 +118,7 @@ TQ_LONG KBufferedSocket::waitForMore(int msecs, bool *timeout)
return retval;
}
-TQ_LONG KBufferedSocket::readBlock(char *data, TQ_ULONG maxlen)
+TQT_TQIO_LONG KBufferedSocket::tqreadBlock(char *data, TQT_TQIO_ULONG maxlen)
{
if (d->input)
{
@@ -131,13 +131,13 @@ TQ_LONG KBufferedSocket::readBlock(char *data, TQ_ULONG maxlen)
resetError();
return d->input->consumeBuffer(data, maxlen);
}
- return KStreamSocket::readBlock(data, maxlen);
+ return KStreamSocket::tqreadBlock(data, maxlen);
}
-TQ_LONG KBufferedSocket::readBlock(char *data, TQ_ULONG maxlen, KSocketAddress& from)
+TQT_TQIO_LONG KBufferedSocket::tqreadBlock(char *data, TQT_TQIO_ULONG maxlen, KSocketAddress& from)
{
from = peerAddress();
- return readBlock(data, maxlen);
+ return tqreadBlock(data, maxlen);
}
TQ_LONG KBufferedSocket::peekBlock(char *data, TQ_ULONG maxlen)
@@ -162,7 +162,7 @@ TQ_LONG KBufferedSocket::peekBlock(char *data, TQ_ULONG maxlen, KSocketAddress&
return peekBlock(data, maxlen);
}
-TQ_LONG KBufferedSocket::writeBlock(const char *data, TQ_ULONG len)
+TQT_TQIO_LONG KBufferedSocket::tqwriteBlock(const char *data, TQT_TQIO_ULONG len)
{
if (state() != Connected)
{
@@ -189,14 +189,14 @@ TQ_LONG KBufferedSocket::writeBlock(const char *data, TQ_ULONG len)
return d->output->feedBuffer(data, len);
}
- return KStreamSocket::writeBlock(data, len);
+ return KStreamSocket::tqwriteBlock(data, len);
}
-TQ_LONG KBufferedSocket::writeBlock(const char *data, TQ_ULONG maxlen,
+TQT_TQIO_LONG KBufferedSocket::tqwriteBlock(const char *data, TQT_TQIO_ULONG maxlen,
const KSocketAddress&)
{
// ignore the third parameter
- return writeBlock(data, maxlen);
+ return tqwriteBlock(data, maxlen);
}
void KBufferedSocket::enableRead(bool enable)
diff --git a/kdecore/network/kbufferedsocket.h b/kdecore/network/kbufferedsocket.h
index 0982a88d3..8f9dde92c 100644
--- a/kdecore/network/kbufferedsocket.h
+++ b/kdecore/network/kbufferedsocket.h
@@ -114,7 +114,7 @@ public:
/**
* Reads data from the socket. Make use of buffers.
*/
- virtual TQ_LONG readBlock(char *data, TQ_ULONG maxlen);
+ virtual TQT_TQIO_LONG tqreadBlock(char *data, TQT_TQIO_ULONG maxlen);
/**
* @overload
@@ -122,7 +122,7 @@ public:
*
* The @p from parameter is always set to @ref peerAddress()
*/
- virtual TQ_LONG readBlock(char *data, TQ_ULONG maxlen, KSocketAddress& from);
+ virtual TQT_TQIO_LONG tqreadBlock(char *data, TQT_TQIO_ULONG maxlen, KSocketAddress& from);
/**
* Peeks data from the socket.
@@ -140,7 +140,7 @@ public:
/**
* Writes data to the socket.
*/
- virtual TQ_LONG writeBlock(const char *data, TQ_ULONG len);
+ virtual TQT_TQIO_LONG tqwriteBlock(const char *data, TQT_TQIO_ULONG len);
/**
* @overload
@@ -148,7 +148,7 @@ public:
*
* The @p to parameter is discarded.
*/
- virtual TQ_LONG writeBlock(const char *data, TQ_ULONG len, const KSocketAddress& to);
+ virtual TQT_TQIO_LONG tqwriteBlock(const char *data, TQT_TQIO_ULONG len, const KSocketAddress& to);
/**
* Catch changes.
diff --git a/kdecore/network/kclientsocketbase.cpp b/kdecore/network/kclientsocketbase.cpp
index 46f7a1942..9785ce36c 100644
--- a/kdecore/network/kclientsocketbase.cpp
+++ b/kdecore/network/kclientsocketbase.cpp
@@ -311,10 +311,10 @@ TQ_LONG KClientSocketBase::waitForMore(int msecs, bool *timeout)
return retval;
}
-TQ_LONG KClientSocketBase::readBlock(char *data, TQ_ULONG maxlen)
+TQT_TQIO_LONG KClientSocketBase::tqreadBlock(char *data, TQT_TQIO_ULONG maxlen)
{
resetError();
- TQ_LONG retval = socketDevice()->readBlock(data, maxlen);
+ TQ_LONG retval = socketDevice()->tqreadBlock(data, maxlen);
if (retval == -1)
{
copyError();
@@ -323,10 +323,10 @@ TQ_LONG KClientSocketBase::readBlock(char *data, TQ_ULONG maxlen)
return retval;
}
-TQ_LONG KClientSocketBase::readBlock(char *data, TQ_ULONG maxlen, KSocketAddress& from)
+TQT_TQIO_LONG KClientSocketBase::tqreadBlock(char *data, TQT_TQIO_ULONG maxlen, KSocketAddress& from)
{
resetError();
- TQ_LONG retval = socketDevice()->readBlock(data, maxlen, from);
+ TQ_LONG retval = socketDevice()->tqreadBlock(data, maxlen, from);
if (retval == -1)
{
copyError();
@@ -359,10 +359,10 @@ TQ_LONG KClientSocketBase::peekBlock(char *data, TQ_ULONG maxlen, KSocketAddress
return retval;
}
-TQ_LONG KClientSocketBase::writeBlock(const char *data, TQ_ULONG len)
+TQT_TQIO_LONG KClientSocketBase::tqwriteBlock(const char *data, TQT_TQIO_ULONG len)
{
resetError();
- TQ_LONG retval = socketDevice()->writeBlock(data, len);
+ TQ_LONG retval = socketDevice()->tqwriteBlock(data, len);
if (retval == -1)
{
copyError();
@@ -371,10 +371,10 @@ TQ_LONG KClientSocketBase::writeBlock(const char *data, TQ_ULONG len)
return retval;
}
-TQ_LONG KClientSocketBase::writeBlock(const char *data, TQ_ULONG len, const KSocketAddress& to)
+TQT_TQIO_LONG KClientSocketBase::tqwriteBlock(const char *data, TQT_TQIO_ULONG len, const KSocketAddress& to)
{
resetError();
- TQ_LONG retval = socketDevice()->writeBlock(data, len, to);
+ TQ_LONG retval = socketDevice()->tqwriteBlock(data, len, to);
if (retval == -1)
{
copyError();
diff --git a/kdecore/network/kclientsocketbase.h b/kdecore/network/kclientsocketbase.h
index 63ddc3aa3..bf1c8c04e 100644
--- a/kdecore/network/kclientsocketbase.h
+++ b/kdecore/network/kclientsocketbase.h
@@ -317,13 +317,13 @@ public:
/**
* Reads data from a socket. Reimplemented from KSocketBase.
*/
- virtual TQ_LONG readBlock(char *data, TQ_ULONG maxlen);
+ virtual TQT_TQIO_LONG tqreadBlock(char *data, TQT_TQIO_ULONG maxlen);
/**
* @overload
* Reads data from a socket. Reimplemented from KSocketBase.
*/
- virtual TQ_LONG readBlock(char *data, TQ_ULONG maxlen, KSocketAddress& from);
+ virtual TQT_TQIO_LONG tqreadBlock(char *data, TQT_TQIO_ULONG maxlen, KSocketAddress& from);
/**
* Peeks data from the socket. Reimplemented from KSocketBase.
@@ -339,13 +339,13 @@ public:
/**
* Writes data to the socket. Reimplemented from KSocketBase.
*/
- virtual TQ_LONG writeBlock(const char *data, TQ_ULONG len);
+ virtual TQT_TQIO_LONG tqwriteBlock(const char *data, TQT_TQIO_ULONG len);
/**
* @overload
* Writes data to the socket. Reimplemented from KSocketBase.
*/
- virtual TQ_LONG writeBlock(const char *data, TQ_ULONG len, const KSocketAddress& to);
+ virtual TQT_TQIO_LONG tqwriteBlock(const char *data, TQT_TQIO_ULONG len, const KSocketAddress& to);
/**
* Returns the local socket address. Reimplemented from KSocketBase.
diff --git a/kdecore/network/kdatagramsocket.cpp b/kdecore/network/kdatagramsocket.cpp
index ff6ea04b3..d4bddc543 100644
--- a/kdecore/network/kdatagramsocket.cpp
+++ b/kdecore/network/kdatagramsocket.cpp
@@ -156,7 +156,7 @@ KDatagramPacket KDatagramSocket::receive()
KSocketAddress address;
// now do the reading
- size = readBlock(data.data(), size, address);
+ size = tqreadBlock(data.data(), size, address);
if (size < 0)
// error has been set
return KDatagramPacket();
@@ -167,10 +167,10 @@ KDatagramPacket KDatagramSocket::receive()
TQ_LONG KDatagramSocket::send(const KDatagramPacket& packet)
{
- return writeBlock(packet.data(), packet.size(), packet.address());
+ return tqwriteBlock(packet.data(), packet.size(), packet.address());
}
-TQ_LONG KDatagramSocket::writeBlock(const char *data, TQ_ULONG len, const KSocketAddress& to)
+TQ_LONG KDatagramSocket::tqwriteBlock(const char *data, TQ_ULONG len, const KSocketAddress& to)
{
if (to.family() != AF_UNSPEC)
{
@@ -179,7 +179,7 @@ TQ_LONG KDatagramSocket::writeBlock(const char *data, TQ_ULONG len, const KSocke
// error handling will happen below
socketDevice()->create(to.family(), SOCK_DGRAM, 0);
}
- return KClientSocketBase::writeBlock(data, len, to);
+ return KClientSocketBase::tqwriteBlock(data, len, to);
}
void KDatagramSocket::lookupFinishedLocal()
diff --git a/kdecore/network/kdatagramsocket.h b/kdecore/network/kdatagramsocket.h
index 7ecbada09..becbe404a 100644
--- a/kdecore/network/kdatagramsocket.h
+++ b/kdecore/network/kdatagramsocket.h
@@ -223,7 +223,7 @@ public:
*
* Connecting means only to designate the given address as the default
* destination address for datagrams sent without destination addresses
- * ( writeBlock(const char *, TQ_ULONG) ).
+ * ( tqwriteBlock(const char *, TQ_ULONG) ).
*
* @note Calling connect will not cause the socket to be bound. You have
* to call @ref bind explicitly.
@@ -241,7 +241,7 @@ public:
/**
* Writes data to the socket. Reimplemented from KClientSocketBase.
*/
- virtual TQ_LONG writeBlock(const char *data, TQ_ULONG len, const KSocketAddress& to);
+ virtual TQ_LONG tqwriteBlock(const char *data, TQ_ULONG len, const KSocketAddress& to);
/**
* Receives one datagram from the stream. The reading process is guaranteed
diff --git a/kdecore/network/khttpproxysocketdevice.cpp b/kdecore/network/khttpproxysocketdevice.cpp
index f4ef01564..0d72b4b3d 100644
--- a/kdecore/network/khttpproxysocketdevice.cpp
+++ b/kdecore/network/khttpproxysocketdevice.cpp
@@ -179,7 +179,7 @@ bool KHttpProxySocketDevice::parseServerReply()
if (!d->request.isEmpty())
{
// send request
- TQ_LONG written = writeBlock(d->request, d->request.length());
+ TQ_LONG written = tqwriteBlock(d->request, d->request.length());
if (written < 0)
{
qDebug("KHttpProxySocketDevice: would block writing request!");
@@ -227,7 +227,7 @@ bool KHttpProxySocketDevice::parseServerReply()
{
// no, headers not yet finished...
// consume data from socket
- readBlock(buf.data(), avail);
+ tqreadBlock(buf.data(), avail);
d->reply += buf.data();
setError(IO_ConnectError, InProgress);
return true;
@@ -238,7 +238,7 @@ bool KHttpProxySocketDevice::parseServerReply()
d->reply += fullHeaders.mid(d->reply.length(), index + 4);
// consume from socket
- readBlock(buf.data(), index + 4);
+ tqreadBlock(buf.data(), index + 4);
}
else
{
diff --git a/kdecore/network/ksocketbase.cpp b/kdecore/network/ksocketbase.cpp
index 1a486ee16..f5410f3e8 100644
--- a/kdecore/network/ksocketbase.cpp
+++ b/kdecore/network/ksocketbase.cpp
@@ -291,7 +291,7 @@ KActiveSocketBase::~KActiveSocketBase()
int KActiveSocketBase::getch()
{
unsigned char c;
- if (readBlock((char*)&c, 1) != 1)
+ if (tqreadBlock((char*)&c, 1) != 1)
return -1;
return c;
@@ -300,7 +300,7 @@ int KActiveSocketBase::getch()
int KActiveSocketBase::putch(int ch)
{
unsigned char c = (unsigned char)ch;
- if (writeBlock((char*)&c, 1) != 1)
+ if (tqwriteBlock((char*)&c, 1) != 1)
return -1;
return c;
diff --git a/kdecore/network/ksocketbase.h b/kdecore/network/ksocketbase.h
index b7df0c35f..8a94cbbcb 100644
--- a/kdecore/network/ksocketbase.h
+++ b/kdecore/network/ksocketbase.h
@@ -562,7 +562,7 @@ public:
* Reimplemented from TQIODevice. See TQIODevice::readBlock for
* more information.
*/
- virtual TQ_LONG readBlock(char *data, TQ_ULONG len) = 0;
+ virtual TQT_TQIO_LONG tqreadBlock(char *data, TQT_TQIO_ULONG len) = 0;
/** @overload
* Receives data and the source address.
@@ -575,7 +575,7 @@ public:
* @param from the address of the sender will be stored here
* @returns the actual number of bytes read
*/
- virtual TQ_LONG readBlock(char *data, TQ_ULONG maxlen, KSocketAddress& from) = 0;
+ virtual TQT_TQIO_LONG tqreadBlock(char *data, TQT_TQIO_ULONG maxlen, KSocketAddress& from) = 0;
/**
* Peeks the data in the socket.
@@ -610,7 +610,7 @@ public:
* Reimplemented from TQIODevice. See TQIODevice::writeBlock for
* more information.
*/
- virtual TQ_LONG writeBlock(const char *data, TQ_ULONG len) = 0;
+ virtual TQT_TQIO_LONG tqwriteBlock(const char *data, TQT_TQIO_ULONG len) = 0;
/** @overload
* Writes the given data to the destination address.
@@ -623,7 +623,7 @@ public:
* @param to the address to send to
* @returns the number of bytes actually sent
*/
- virtual TQ_LONG writeBlock(const char *data, TQ_ULONG len, const KSocketAddress& to) = 0;
+ virtual TQT_TQIO_LONG tqwriteBlock(const char *data, TQT_TQIO_ULONG len, const KSocketAddress& to) = 0;
/**
* Reads one character from the socket.
diff --git a/kdecore/network/ksocketbuffer.cpp b/kdecore/network/ksocketbuffer.cpp
index 4ea12ed14..ad4864be7 100644
--- a/kdecore/network/ksocketbuffer.cpp
+++ b/kdecore/network/ksocketbuffer.cpp
@@ -273,7 +273,7 @@ TQ_LONG KSocketBuffer::sendTo(KActiveSocketBase* dev, TQ_LONG len)
}
// now try to write those bytes
- TQ_LONG wrote = dev->writeBlock(buf, count);
+ TQ_LONG wrote = dev->tqwriteBlock(buf, count);
if (wrote == -1)
// error?
@@ -314,7 +314,7 @@ TQ_LONG KSocketBuffer::receiveFrom(KActiveSocketBase* dev, TQ_LONG len)
// now do the reading
TQByteArray a(len);
- len = dev->readBlock(a.data(), len);
+ len = dev->tqreadBlock(a.data(), len);
if (len == -1)
// error?
diff --git a/kdecore/network/ksocketdevice.cpp b/kdecore/network/ksocketdevice.cpp
index 793642bf9..8b4789e02 100644
--- a/kdecore/network/ksocketdevice.cpp
+++ b/kdecore/network/ksocketdevice.cpp
@@ -419,7 +419,7 @@ static int do_read_common(int sockfd, char *data, TQ_ULONG maxlen, KSocketAddres
return 0;
}
-TQ_LONG KSocketDevice::readBlock(char *data, TQ_ULONG maxlen)
+TQT_TQIO_LONG KSocketDevice::tqreadBlock(char *data, TQT_TQIO_ULONG maxlen)
{
resetError();
if (m_sockfd == -1)
@@ -440,7 +440,7 @@ TQ_LONG KSocketDevice::readBlock(char *data, TQ_ULONG maxlen)
return retval;
}
-TQ_LONG KSocketDevice::readBlock(char *data, TQ_ULONG maxlen, KSocketAddress &from)
+TQT_TQIO_LONG KSocketDevice::tqreadBlock(char *data, TQT_TQIO_ULONG maxlen, KSocketAddress &from)
{
resetError();
if (m_sockfd == -1)
@@ -503,12 +503,12 @@ TQ_LONG KSocketDevice::peekBlock(char *data, TQ_ULONG maxlen, KSocketAddress& fr
return retval;
}
-TQ_LONG KSocketDevice::writeBlock(const char *data, TQ_ULONG len)
+TQT_TQIO_LONG KSocketDevice::tqwriteBlock(const char *data, TQT_TQIO_ULONG len)
{
- return writeBlock(data, len, KSocketAddress());
+ return tqwriteBlock(data, len, KSocketAddress());
}
-TQ_LONG KSocketDevice::writeBlock(const char *data, TQ_ULONG len, const KSocketAddress& to)
+TQT_TQIO_LONG KSocketDevice::tqwriteBlock(const char *data, TQT_TQIO_ULONG len, const KSocketAddress& to)
{
resetError();
if (m_sockfd == -1)
diff --git a/kdecore/network/ksocketdevice.h b/kdecore/network/ksocketdevice.h
index 5324cd02b..5409335aa 100644
--- a/kdecore/network/ksocketdevice.h
+++ b/kdecore/network/ksocketdevice.h
@@ -216,12 +216,12 @@ public:
/**
* Reads data from this socket.
*/
- virtual TQ_LONG readBlock(char *data, TQ_ULONG maxlen);
+ virtual TQT_TQIO_LONG tqreadBlock(char *data, TQT_TQIO_ULONG maxlen);
/**
* Reads data and the source address from this socket.
*/
- virtual TQ_LONG readBlock(char *data, TQ_ULONG maxlen, KSocketAddress& from);
+ virtual TQT_TQIO_LONG tqreadBlock(char *data, TQT_TQIO_ULONG maxlen, KSocketAddress& from);
/**
* Peeks data in the socket.
@@ -236,12 +236,12 @@ public:
/**
* Writes data to the socket.
*/
- virtual TQ_LONG writeBlock(const char *data, TQ_ULONG len);
+ virtual TQT_TQIO_LONG tqwriteBlock(const char *data, TQT_TQIO_ULONG len);
/**
* Writes the given data to the given destination address.
*/
- virtual TQ_LONG writeBlock(const char *data, TQ_ULONG len, const KSocketAddress& to);
+ virtual TQT_TQIO_LONG tqwriteBlock(const char *data, TQT_TQIO_ULONG len, const KSocketAddress& to);
/**
* Returns this socket's local address.
diff --git a/kdecore/network/ksockssocketdevice.cpp b/kdecore/network/ksockssocketdevice.cpp
index b9fcb6cdd..3432ef84f 100644
--- a/kdecore/network/ksockssocketdevice.cpp
+++ b/kdecore/network/ksockssocketdevice.cpp
@@ -214,7 +214,7 @@ static int socks_read_common(int sockfd, char *data, TQ_ULONG maxlen, KSocketAdd
return 0;
}
-TQ_LONG KSocksSocketDevice::readBlock(char *data, TQ_ULONG maxlen)
+TQ_LONG KSocksSocketDevice::tqreadBlock(char *data, TQ_ULONG maxlen)
{
resetError();
if (m_sockfd == -1)
@@ -235,7 +235,7 @@ TQ_LONG KSocksSocketDevice::readBlock(char *data, TQ_ULONG maxlen)
return retval;
}
-TQ_LONG KSocksSocketDevice::readBlock(char *data, TQ_ULONG maxlen, KSocketAddress &from)
+TQ_LONG KSocksSocketDevice::tqreadBlock(char *data, TQ_ULONG maxlen, KSocketAddress &from)
{
resetError();
if (m_sockfd == -1)
@@ -298,12 +298,12 @@ TQ_LONG KSocksSocketDevice::peekBlock(char *data, TQ_ULONG maxlen, KSocketAddres
return retval;
}
-TQ_LONG KSocksSocketDevice::writeBlock(const char *data, TQ_ULONG len)
+TQ_LONG KSocksSocketDevice::tqwriteBlock(const char *data, TQ_ULONG len)
{
- return writeBlock(data, len, KSocketAddress());
+ return tqwriteBlock(data, len, KSocketAddress());
}
-TQ_LONG KSocksSocketDevice::writeBlock(const char *data, TQ_ULONG len, const KSocketAddress& to)
+TQ_LONG KSocksSocketDevice::tqwriteBlock(const char *data, TQ_ULONG len, const KSocketAddress& to)
{
resetError();
if (m_sockfd == -1)
diff --git a/kdecore/network/ksockssocketdevice.h b/kdecore/network/ksockssocketdevice.h
index 1f8453836..4db5d1e01 100644
--- a/kdecore/network/ksockssocketdevice.h
+++ b/kdecore/network/ksockssocketdevice.h
@@ -83,8 +83,8 @@ public:
/**
* Overrides reading.
*/
- virtual TQ_LONG readBlock(char *data, TQ_ULONG maxlen);
- virtual TQ_LONG readBlock(char *data, TQ_ULONG maxlen, KSocketAddress& from);
+ virtual TQ_LONG tqreadBlock(char *data, TQ_ULONG maxlen);
+ virtual TQ_LONG tqreadBlock(char *data, TQ_ULONG maxlen, KSocketAddress& from);
/**
* Overrides peeking.
@@ -95,8 +95,8 @@ public:
/**
* Overrides writing.
*/
- virtual TQ_LONG writeBlock(const char *data, TQ_ULONG len);
- virtual TQ_LONG writeBlock(const char *data, TQ_ULONG len, const KSocketAddress& to);
+ virtual TQ_LONG tqwriteBlock(const char *data, TQ_ULONG len);
+ virtual TQ_LONG tqwriteBlock(const char *data, TQ_ULONG len, const KSocketAddress& to);
/**
* Overrides getting socket address.