Commit d586ab0
committed
Use RAII guards for HNSW node locks and harden multi-lock paths
- Replace manual lock/unlock pairs with std::shared_lock/std::unique_lock in hnsw.h and hnsw_batch_iterator.h to make lock release scope-safe across early exits.
- Deduplicate sorted node lock sets and guard against self-neighbor locking before acquiring paired locks, reducing deadlock/pathological lock risks without changing lock semantics.1 parent 111df16 commit d586ab0
2 files changed
Lines changed: 134 additions & 135 deletions
0 commit comments