benilla-re systems structs docs

s_socketBitmapLock

global · net

Address
0xc2a354 · 24 bytes, up to 0xc2a36b
Type
uint8_t[24]
Meaning
Holds the lock over the open-socket bitmap
Confidence
verified, proof one
Finding
net/threads#socket-bitmap-and-callback-bracket

Finding: Socket bitmap and callback bracket in net: threads

MarkSocketOpen (0x5b6330, socket in ecx) sets bit fd & 31 of word fd >> 5 of the bitmap [0xc2a378], under the lock 0xc2a354; a negative socket does nothing. WowConnection::BeginCallback (0x5b7260) adds one to the running callbacks at +0xb4 and records the thread at +0xb8; EndCallback (0x5b7290) subtracts one and, when +0xbc holds a value, moves it to +0x14 and clears +0xbc, whatever the count. Both run under the connection's lock +0x9c.

The derivation is in the doc.