diff --git a/src/blobstore/implementations/onblocks/datatreestore/DataTree.cpp b/src/blobstore/implementations/onblocks/datatreestore/DataTree.cpp index 530d5a24..75209e25 100644 --- a/src/blobstore/implementations/onblocks/datatreestore/DataTree.cpp +++ b/src/blobstore/implementations/onblocks/datatreestore/DataTree.cpp @@ -246,7 +246,7 @@ unique_ref DataTree::addChildTo(DataInnerNode *node) { new_leaf->resize(_nodeStore->layout().maxBytesPerLeaf()); auto chain = createChainOfInnerNodes(node->depth()-1, std::move(new_leaf)); node->addChild(*chain); - return std::move(chain); + return chain; } uint32_t DataTree::leavesPerFullChild(const DataInnerNode &root) const { diff --git a/src/blockstore/implementations/ondisk/OnDiskBlockStore.cpp b/src/blockstore/implementations/ondisk/OnDiskBlockStore.cpp index a3ea3bb6..e6573f40 100644 --- a/src/blockstore/implementations/ondisk/OnDiskBlockStore.cpp +++ b/src/blockstore/implementations/ondisk/OnDiskBlockStore.cpp @@ -58,7 +58,7 @@ bool OnDiskBlockStore::_isValidBlockKey(const string &key) { optional> OnDiskBlockStore::tryCreate(const Key &key, Data data) { //TODO Easier implementation? This is only so complicated because of the cast OnDiskBlock -> Block - auto result = std::move(OnDiskBlock::CreateOnDisk(_rootdir, key, std::move(data))); + auto result = OnDiskBlock::CreateOnDisk(_rootdir, key, std::move(data)); if (result == boost::none) { return boost::none; } diff --git a/src/cpp-utils/data/Data.cpp b/src/cpp-utils/data/Data.cpp index cd37683c..ea760eca 100644 --- a/src/cpp-utils/data/Data.cpp +++ b/src/cpp-utils/data/Data.cpp @@ -34,7 +34,7 @@ std::streampos Data::_getStreamSize(istream &stream) { Data Data::LoadFromStream(istream &stream, size_t size) { Data result(size); stream.read(static_cast(result.data()), result.size()); - return std::move(result); + return result; } }