Skip to content

Fix non-threadsafe hash-table accesses

Pre-release
Pre-release
Compare
Choose a tag to compare
@graebm graebm released this 13 Apr 14:23
· 116 commits to main since this release
8612b55
Fix unsafe hash-table accesses (#189)

Fact: It's not safe to mutate aws_hash_table while holding an aws_hash_element.
Fact: `outstanding_requests_table` is accessed by multiple threads. We always hold a lock while accessing it.

Bug: There were several places where we release the lock, but continue to hold an aws_hash_element we got from a find() call. Once the lock is released another thread can mutate the `outstanding_requests_table`, leading to undefined behavior when the aws_hash_element is accessed again.