diff options
| author | Niles Salter <Validark@pm.me> | 2023-06-20 21:05:12 -0600 |
|---|---|---|
| committer | Andrew Kelley <andrew@ziglang.org> | 2023-06-22 02:03:53 -0700 |
| commit | 82470d4f892af2efa64acd58ab3188fa917ace0c (patch) | |
| tree | 86fc03ba6899051e78a57d3c3ebdb3004ea5044f /src/windows_sdk.cpp | |
| parent | ff5850183eee854fdfe0d3f7b7242b9ff56c2116 (diff) | |
| download | zig-82470d4f892af2efa64acd58ab3188fa917ace0c.tar.gz zig-82470d4f892af2efa64acd58ab3188fa917ace0c.zip | |
[priority_dequeue] Fix out-of-bounds access
This makes it so `first_child_index` will not be accessed when it is equal to `self.len`. (i.e. `self.items[self.len]` will not happen) The access itself was "safe" (as in, `self.len < self.items.len`) because we were only calling `doSiftDown` in the case where there was a stale value at `self.items[self.len]`. However, it is still technically a bug, and can manifest by an unnecessary comparison of a value to a copy of itself.
Diffstat (limited to 'src/windows_sdk.cpp')
0 files changed, 0 insertions, 0 deletions
