Fixed a error message when quit