summaryrefslogtreecommitdiff
path: root/share
diff options
context:
space:
mode:
authorTodd Gamblin <tgamblin@llnl.gov>2019-12-21 16:23:54 -0800
committerTodd Gamblin <tgamblin@llnl.gov>2019-12-23 23:18:44 -0800
commit98577e3af5cf571d5408fcb1da32de3586238ead (patch)
tree22574a3cfb61158d0abb8426ffa2f832044c9610 /share
parenta85b9070cb37103c45e0e9b58732b4d92c09288b (diff)
downloadspack-98577e3af5cf571d5408fcb1da32de3586238ead.tar.gz
spack-98577e3af5cf571d5408fcb1da32de3586238ead.tar.bz2
spack-98577e3af5cf571d5408fcb1da32de3586238ead.tar.xz
spack-98577e3af5cf571d5408fcb1da32de3586238ead.zip
lock transactions: fix non-transactional writes
Lock transactions were actually writing *after* the lock was released. The code was looking at the result of `release_write()` before writing, then writing based on whether the lock was released. This is pretty obviously wrong. - [x] Refactor `Lock` so that a release function can be passed to the `Lock` and called *only* when a lock is really released. - [x] Refactor `LockTransaction` classes to use the release function instead of checking the return value of `release_read()` / `release_write()`
Diffstat (limited to 'share')
0 files changed, 0 insertions, 0 deletions