fixed the bug which the master coredump , when the worker exited.