Catch error on stream