Set stopped event in the first place before any exception