added resources releasing