diff options
author | Christian Mollekopf <chrigi_1@fastmail.fm> | 2015-01-24 23:38:12 +0100 |
---|---|---|
committer | Christian Mollekopf <chrigi_1@fastmail.fm> | 2015-01-24 23:38:12 +0100 |
commit | 9b744da32e64d8a6cd342faba8fc3232884d60f2 (patch) | |
tree | a22558b6c869ba777292d3ce231222408614d5b3 /common/resourceaccess.cpp | |
parent | b36ae2d0e0b0ee9865fdc7e628374853d160b55a (diff) | |
download | sink-9b744da32e64d8a6cd342faba8fc3232884d60f2.tar.gz sink-9b744da32e64d8a6cd342faba8fc3232884d60f2.zip |
Uid index + query using that index.
...and a couple of other fixes.
Diffstat (limited to 'common/resourceaccess.cpp')
-rw-r--r-- | common/resourceaccess.cpp | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/common/resourceaccess.cpp b/common/resourceaccess.cpp index 5f04db8..73a01ca 100644 --- a/common/resourceaccess.cpp +++ b/common/resourceaccess.cpp | |||
@@ -298,6 +298,7 @@ bool ResourceAccess::processMessageBuffer() | |||
298 | { | 298 | { |
299 | static const int headerSize = Commands::headerSize(); | 299 | static const int headerSize = Commands::headerSize(); |
300 | if (d->partialMessageBuffer.size() < headerSize) { | 300 | if (d->partialMessageBuffer.size() < headerSize) { |
301 | qWarning() << "command too small"; | ||
301 | return false; | 302 | return false; |
302 | } | 303 | } |
303 | 304 | ||
@@ -306,6 +307,7 @@ bool ResourceAccess::processMessageBuffer() | |||
306 | const uint size = *(int*)(d->partialMessageBuffer.constData() + sizeof(int) + sizeof(uint)); | 307 | const uint size = *(int*)(d->partialMessageBuffer.constData() + sizeof(int) + sizeof(uint)); |
307 | 308 | ||
308 | if (size > (uint)(d->partialMessageBuffer.size() - headerSize)) { | 309 | if (size > (uint)(d->partialMessageBuffer.size() - headerSize)) { |
310 | qWarning() << "command too small"; | ||
309 | return false; | 311 | return false; |
310 | } | 312 | } |
311 | 313 | ||