remove unnecessary code from lock.inc