summaryrefslogtreecommitdiffhomepage
path: root/tracker-hatire
diff options
context:
space:
mode:
authorStanislaw Halik <sthalik@misaki.pl>2016-05-06 09:16:04 +0200
committerStanislaw Halik <sthalik@misaki.pl>2016-05-06 09:18:21 +0200
commit5d3572e15b063ccdf2fc5adde8fa9f2d4d3553be (patch)
treefe0d21ae0d7f711df2198bf1b0b8b64c72d1fb2e /tracker-hatire
parent9d20fa89ffdb49a3da20812e2eaa0ee2d9a24f5b (diff)
tracker/hatire: don't hoard more data than a single dgram
The resync code already worked without that.
Diffstat (limited to 'tracker-hatire')
-rwxr-xr-xtracker-hatire/thread.cpp4
1 files changed, 1 insertions, 3 deletions
diff --git a/tracker-hatire/thread.cpp b/tracker-hatire/thread.cpp
index 5df3a68c..ace4198c 100755
--- a/tracker-hatire/thread.cpp
+++ b/tracker-hatire/thread.cpp
@@ -319,10 +319,8 @@ void hatire_thread::on_serial_read()
QByteArray& hatire_thread::send_data_read_nolock(bool& ret)
{
constexpr int packet_len = 30;
- constexpr int cnt = 4;
- constexpr int len = cnt * packet_len;
- if (data_read.length() < len)
+ if (data_read.length() < packet_len)
{
// we're requesting more than packet length to help resync the stream if needed
ret = false;