summaryrefslogtreecommitdiffstats
path: root/libktorrent/torrent/utpex.cpp
diff options
context:
space:
mode:
authortpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2011-06-28 20:34:15 +0000
committertpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2011-06-28 20:34:15 +0000
commit1c1403293485f35fd53db45aaa77a01cdd9627e7 (patch)
tree38559cd68cd4f63023fb5f6375def9db3b8b491e /libktorrent/torrent/utpex.cpp
parent894f94545727610df22c4f73911d62d58266f695 (diff)
downloadktorrent-1c1403293485f35fd53db45aaa77a01cdd9627e7.tar.gz
ktorrent-1c1403293485f35fd53db45aaa77a01cdd9627e7.zip
TQt4 port ktorrent
This enables compilation under both Qt3 and Qt4 git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/applications/ktorrent@1238733 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'libktorrent/torrent/utpex.cpp')
-rw-r--r--libktorrent/torrent/utpex.cpp16
1 files changed, 8 insertions, 8 deletions
diff --git a/libktorrent/torrent/utpex.cpp b/libktorrent/torrent/utpex.cpp
index 4933218..68361e0 100644
--- a/libktorrent/torrent/utpex.cpp
+++ b/libktorrent/torrent/utpex.cpp
@@ -46,7 +46,7 @@ namespace bt
if (size <= 2 || packet[1] != 1)
return;
- QByteArray tmp;
+ TQByteArray tmp;
tmp.setRawData((const char*)packet,size);
BNode* node = 0;
try
@@ -61,7 +61,7 @@ namespace bt
BValueNode* val = dict->getValue("added");
if (val)
{
- QByteArray data = val->data().toByteArray();
+ TQByteArray data = val->data().toByteArray();
peer->emitPex(data);
}
}
@@ -111,14 +111,14 @@ namespace bt
if (!(peers.size() == 0 && added.size() == 0))
{
// encode the whole lot
- QByteArray data;
+ TQByteArray data;
BEncoder enc(new BEncoderBufferOutput(data));
enc.beginDict();
- enc.write("added");
+ enc.write(TQString("added"));
encode(enc,added);
- enc.write("added.f"); // no idea what this added.f thing means
- enc.write("");
- enc.write("dropped");
+ enc.write(TQString("added.f")); // no idea what this added.f thing means
+ enc.write(TQString(""));
+ enc.write(TQString("dropped"));
encode(enc,peers);
enc.end();
@@ -132,7 +132,7 @@ namespace bt
{
if (ps.size() == 0)
{
- enc.write("");
+ enc.write(TQString(""));
return;
}