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

Refactor __wt_session_set_last_error to void function and prevent error overwrite

    • Type: Icon: Task Task
    • Resolution: Fixed
    • Priority: Icon: Major - P3 Major - P3
    • WT12.0.0, 8.1.0-rc0
    • Affects Version/s: None
    • Component/s: APIs
    • None
    • Storage Engines
    • 1

      This ticket aims to prevent the overwriting of the err_info struct in the session whenever there is the case of __wt_session_set_last_error being called twice to set an error in one session API call. Overwriting the err_info struct should only be done when resetting the struct after each API call. The error from the deepest point in the call stack should take precedence. This ticket also aims to change the function return value to void. Instead of returning an error code if an error occurs within the function, it should abort.

      Definition of Done
      After each session API call, the deepest error in the stack should be the error inside the err_info struct, with python and unit tests created. The function should now have a void return value, and all areas using the function is changed to account for this.

            Assignee:
            dylan.liang@mongodb.com Dylan Liang (Inactive)
            Reporter:
            dylan.liang@mongodb.com Dylan Liang (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved: