1
0
Fork 0

Another snapshot.

This commit is contained in:
Max Neunhoeffer 2015-12-04 23:05:45 +01:00
parent 48ca59b4c0
commit fad55bda0e
3 changed files with 8 additions and 1 deletions

View File

@ -1106,6 +1106,10 @@ static void CreateCollectionCoordinator (const v8::FunctionCallbackInfo<v8::Valu
auto idxJson = primaryIndex->toJson(TRI_UNKNOWN_MEM_ZONE, false); auto idxJson = primaryIndex->toJson(TRI_UNKNOWN_MEM_ZONE, false);
TRI_json_t* index = idxJson.json(); TRI_json_t* index = idxJson.json();
auto indexVelocy = triagens::basics::JsonHelper::toVelocyPack(index);
TRI_FreeJson(TRI_UNKNOWN_MEM_ZONE, index);
velocy.add(indexVelocy->slice());
TRI_json_t* indexes; TRI_json_t* indexes;
TRI_json_t* json; TRI_json_t* json;

View File

@ -57,4 +57,5 @@ void TRI_InitV8indexArangoDB (v8::Isolate* isolate,
void TRI_InitV8indexCollection (v8::Isolate* isolate, void TRI_InitV8indexCollection (v8::Isolate* isolate,
v8::Handle<v8::ObjectTemplate> rt); v8::Handle<v8::ObjectTemplate> rt);
#endif #endif

View File

@ -310,7 +310,9 @@ namespace triagens {
TRI_json_t const* json, TRI_json_t const* json,
std::shared_ptr<arangodb::velocypack::Builder> builder) { std::shared_ptr<arangodb::velocypack::Builder> builder) {
std::string tmp = toString(json); std::string tmp = toString(json);
arangodb::velocypack::Parser parser(builder); arangodb::velocypack::Options opt;
opt.clearBuilderBeforeParse = false;
arangodb::velocypack::Parser parser(builder, &opt);
try { try {
parser.parse(tmp); parser.parse(tmp);
} }