fix signal handles