diff options
author | deva <deva> | 2008-08-15 12:49:58 +0000 |
---|---|---|
committer | deva <deva> | 2008-08-15 12:49:58 +0000 |
commit | ff724eaf74e1df5e467e27bd64ddde9e1b17d9b2 (patch) | |
tree | 7ba23380add299e2508651580eb6254225547df4 /client | |
parent | 5ccdf6dd987be086a8712a4960f770122b1b499b (diff) |
Made client stop reading upon complete xml document and not on connection termination.
Diffstat (limited to 'client')
-rw-r--r-- | client/sendrecieve.cc | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/client/sendrecieve.cc b/client/sendrecieve.cc index 95593c6..454ce30 100644 --- a/client/sendrecieve.cc +++ b/client/sendrecieve.cc @@ -144,6 +144,12 @@ void SendRecieve::myReadyReadHandler() ba = tcpsocket->readAll(); ba_all.append(ba); + + // HACK: To test if the received data is a complete xml document. + QDomDocument doc; + if(doc.setContent(ba_all)) { + has_result = true; + } } QByteArray SendRecieve::getResult() |