GSP
Quick Navigator

Search Site

Unix VPS
A - Starter
B - Basic
C - Preferred
D - Commercial
MPS - Dedicated
Previous VPSs
* Sign Up! *

Support
Contact Us
Online Help
Handbooks
Domain Status
Man Pages

FAQ
Virtual Servers
Pricing
Billing
Technical

Network
Facilities
Connectivity
Topology Map

Miscellaneous
Server Agreement
Year 2038
Credits
 

USA Flag

 

 

Man Pages
BSON_INIT_STATIC(3) libbson BSON_INIT_STATIC(3)

bool
bson_init_static (bson_t *b, const uint8_t *data, size_t length);


  • b: A bson_t.
  • data: A buffer to initialize with.
  • length: The length of data in bytes.

The bson_init_static() function shall initialize a read-only bson_t on the stack using the data provided. No copies of the data will be made and therefore must remain valid for the lifetime of the bson_t.

The resulting bson_t has internal references and therefore must not be copied to avoid dangling pointers in the copy.

Returns true if bson_t was successfully initialized, otherwise false. The function can fail if data or length are invalid.

MongoDB, Inc

2009-present, MongoDB, Inc.

July 3, 2025 1.30.4

Search for    or go to Top of page |  Section 3 |  Main Index

Powered by GSP Visit the GSP FreeBSD Man Page Interface.
Output converted with ManDoc.