fixed leaked window