Described automatic release/regaining locks (closes #24)