MCPcopy Create free account
hub / github.com/FoundationDB/fdb-document-layer / ExtMsgKillCursors

Method ExtMsgKillCursors

src/ExtMsg.actor.cpp:1302–1317  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1300}
1301
1302ExtMsgKillCursors::ExtMsgKillCursors(ExtMsgHeader* header, const uint8_t* body) : header(header) {
1303 const uint8_t* ptr = body;
1304 const uint8_t* eom = (const uint8_t*)header + header->messageLength;
1305
1306 // Mongo OP_KILL_CURSORS begins with int32 ZERO, reserved for future use
1307 ptr += sizeof(int32_t);
1308 numberOfCursorIDs = *(int32_t*)ptr;
1309 // Totally unnecessary for this to be in the message given that we know the overall message length...
1310 ptr += sizeof(int32_t);
1311 cursorIDs = new int64_t[numberOfCursorIDs];
1312
1313 memcpy(cursorIDs, ptr, numberOfCursorIDs * sizeof(int64_t));
1314 ptr += numberOfCursorIDs * sizeof(int64_t);
1315
1316 ASSERT(ptr == eom);
1317}
1318
1319std::string ExtMsgKillCursors::toString() {
1320 return format("KILL_CURSORS: ");

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected