-
Type:
Bug
-
Resolution: Unresolved
-
Priority:
Minor - P4
-
None
-
Affects Version/s: None
-
Component/s: Block Manager
-
Storage Engines - Persistence
-
8,630.78
-
StorEng - Defined Pipeline
-
None
Dereference before null check
There may be a null pointer dereference, or else the comparison against null is unnecessary. All paths that lead to this null pointer comparison already dereference the pointer earlier.
Originally reported against src/block_cache/block_io.c:416 and :423 (REVERSE_INULL 168237). The block cache was removed and the file renamed to src/block_mgr/block_io.c (WT-19017, #15113); the defect survives the refactor at two sites:
- __wt_bm_read_page: dsk->mem_size is dereferenced by __wt_buf_set on paths leading to the if (dsk != NULL) statistics block
- __wt_bm_write_page: dsk->write_gen and dsk->mem_size are dereferenced (the WT_ASSERT and the mem_size assignment, before the if (dsk != NULL) statistics block.
- is related to
-
WT-19017 Merge legacy block cache deprecation feature branch into develop
-
- Closed
-