Fix:
   fix the problem of crash when program exit.