diff options
Diffstat (limited to 'libutils/SharedBuffer.h')
-rw-r--r-- | libutils/SharedBuffer.h | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/libutils/SharedBuffer.h b/libutils/SharedBuffer.h index fdf13a9e7..476c842fe 100644 --- a/libutils/SharedBuffer.h +++ b/libutils/SharedBuffer.h @@ -102,7 +102,12 @@ private: // Must be sized to preserve correct alignment. mutable std::atomic<int32_t> mRefs; size_t mSize; - uint32_t mReserved[2]; + uint32_t mReserved; +public: + // mClientMetadata is reserved for client use. It is initialized to 0 + // and the clients can do whatever they want with it. Note that this is + // placed last so that it is adjcent to the buffer allocated. + uint32_t mClientMetadata; }; static_assert(sizeof(SharedBuffer) % 8 == 0 |