Uploaded image for project: 'C Driver'
  1. C Driver
  2. CDRIVER-2838

Document ObjectID unsafe functions

    • Type: Icon: Improvement Improvement
    • Resolution: Fixed
    • Priority: Icon: Trivial - P5 Trivial - P5
    • 1.25.0
    • Affects Version/s: None
    • Component/s: Docs, libbson
    • None

      There are multiple functions that operate on ObjectIDs in libbson that have unsafe variants:

      bson_oid_compare_unsafe
      bson_oid_equal_unsafe
      bson_oid_hash_unsafe
      bson_oid_copy_unsafe
      bson_oid_init_from_string_unsafe
      bson_oid_get_time_t_unsafe
      

      The unsafe variants omit null checks and are marked inline. They are undocumented.
      The "safe" variants just check that arguments are not null before calling the unsafe variant.

            Assignee:
            adrian.dole@mongodb.com Adrian Dole
            Reporter:
            kevin.albertson@mongodb.com Kevin Albertson
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved: