1
0
Fork 0

mini modifications

This commit is contained in:
jsteemann 2017-03-30 15:50:23 +02:00
parent 1d3149c31b
commit 894666915d
2 changed files with 4 additions and 4 deletions

View File

@ -772,7 +772,6 @@ static void JS_DocumentVocbaseCol(
TRI_V8_TRY_CATCH_END
}
#ifndef USE_ENTERPRISE
////////////////////////////////////////////////////////////////////////////////
/// @brief unloads a collection, case of a coordinator in a cluster

View File

@ -46,8 +46,9 @@ class ManagedDocumentResult {
ManagedDocumentResult& operator=(ManagedDocumentResult&& other){
if (other._useString){
setManaged(std::move(other._string), other._lastRevisionId);
}
else if (other._managed){
other._managed = false;
other.reset();
} else if (other._managed){
reset();
_vpack = other._vpack;
_length = other._length;
@ -96,7 +97,7 @@ class ManagedDocumentResult {
inline void setManaged(std::string&& str, TRI_voc_rid_t revisionId) {
reset();
_string = std::move(str);
_vpack = reinterpret_cast<uint8_t*>(const_cast<char *>(_string.data()));
_vpack = reinterpret_cast<uint8_t*>(const_cast<char*>(_string.data()));
_lastRevisionId = revisionId;
_useString = true;
}