modified lock.c and scheduler.c to fix error. hopefully...