minor fix that should make for more careful locking