Initialize mutex/condition variables, lock/unlock around condition broadcast.