MCPcopy Create free account
hub / github.com/Snapchat/KeyDB / bitmapSetBit

Function bitmapSetBit

src/cluster.cpp:3873–3877  ·  view source on GitHub ↗

Set the bit at position 'pos' in a bitmap. */

Source from the content-addressed store, hash-verified

3871
3872/* Set the bit at position 'pos' in a bitmap. */
3873void bitmapSetBit(unsigned char *bitmap, int pos) {
3874 off_t byte = pos/8;
3875 int bit = pos&7;
3876 bitmap[byte] |= 1<<bit;
3877}
3878
3879/* Clear the bit at position 'pos' in a bitmap. */
3880void bitmapClearBit(unsigned char *bitmap, int pos) {

Callers 1

clusterNodeSetSlotBitFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected