Uploaded image for project: 'WiredTiger'
  1. WiredTiger
  2. WT-5749

Only pass a non-NULL WT_ITEM value when allocating a WT_UPDATE with associated data

    • Type: Icon: Technical Debt Technical Debt
    • Resolution: Fixed
    • Priority: Icon: Minor - P4 Minor - P4
    • WT10.0.0, 4.4.0-rc4, 4.7.0
    • Affects Version/s: None
    • Component/s: None
    • None
    • 5
    • Storage - Tora 2020-04-20, Storage - Tora 2020-05-04

      Allocating a tombstone is currently done with the same function, __wt_update_alloc, that allocates update structures holding values. That means it is possible for callers to request a WT_UPDATE_TOMBSTONE but also pass in a non-NULL value. Indeed, that led to bugs and was fixed in WT-5745.

      Rather than fixing things up inside __wt_update_alloc, implement a better approach that means it is impossible for calling code to make this mistake.

            Assignee:
            keith.bostic@mongodb.com Keith Bostic (Inactive)
            Reporter:
            michael.cahill@mongodb.com Michael Cahill (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved: