Close the stream on exit
Added custom pop up