MONGOC_READ_PREFS_DESTROY(3)

πŸ’… MONGOC_READ_PREFS_DESTROY(3) πŸ’…

okay bestie, welcome to the libmongoc corner of the manual β€” this one's a tiny little icon and honestly kind of a palate cleanser 🫢


✨ SYNOPSIS ✨

void
mongoc_read_prefs_destroy (mongoc_read_prefs_t *read_prefs);

like, that's the whole thing. one function. no notes. she's simple, she's elegant, she does exactly one job πŸ’–


πŸŽ€ PARAMETERS πŸŽ€

  • read_prefs β€” a mongoc_read_prefs_t. that's the read preference you're about to send to the shadow realm, no cap πŸ¦‹

🌸 DESCRIPTION 🌸

so basically: mongoc_read_prefs_destroy() frees a read preference and all its associated resources. everything it's holding onto? gone. released. returned to the universe 🌈

and the bestie behaviour we love to see: it does nothing if read_prefs is NULL. so you don't have to do a vibe check before calling it β€” passing NULL is completely safe and it literally just chills πŸ’… periodt.

ngl this is the "cleanup era" function β€” call it when you're done with your mongoc_read_prefs_t so you're not out here leaking memory like it's a personality trait 😭

πŸ‘‘ AUTHOR πŸ‘‘

MongoDB, Inc β€” the main characters themselves ✨


2009-present, MongoDB, Inc. β€” iconic run, honestly πŸŽ€


and that's a wrap, bestie!! πŸ¦‹ this page is from libmongoc version 2.5.6, dated Oct 09, 2026 β€” screenshot it, bookmark it, tattoo it on your forearm, iykyk πŸ’œπŸ”₯ slay responsibly and free your read prefs πŸ§šπŸ“

πŸ“¦ where this page comes from