From 42f32ea5865c95028c577000e15e8a8631d16e74 Mon Sep 17 00:00:00 2001 From: Christian Mollekopf Date: Mon, 30 Mar 2015 23:38:45 +0200 Subject: Storage: API cleanup/use QByteArray instead of std::string --- tests/hawd/dataset.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'tests/hawd') diff --git a/tests/hawd/dataset.cpp b/tests/hawd/dataset.cpp index e1f9700..9f1d307 100644 --- a/tests/hawd/dataset.cpp +++ b/tests/hawd/dataset.cpp @@ -253,7 +253,7 @@ void Dataset::eachRow(const std::function &resultHandler) } Row row(*this); - m_storage.scan(nullptr, 0, + m_storage.scan("", [&](void *key, int keySize, void *data, int dataSize) -> bool { if (keySize != sizeof(qint64)) { return true; @@ -277,7 +277,7 @@ Dataset::Row Dataset::row(qint64 key) } Row row(*this, key); - m_storage.scan((const char *)&key, sizeof(qint64), + m_storage.scan(QByteArray::fromRawData((const char *)&key, sizeof(qint64)), [&row](void *keyPtr, int keyLength, void *valuePtr, int valueSize) -> bool { QByteArray array((const char*)valuePtr, valueSize); row.fromBinary(array); -- cgit v1.2.3