[eluser]TheFuzzy0ne[/eluser]
I think that's your answer. The only output is what you've echoed, and the error appears immediately after.
It seems pretty pointless to me echoing a message and redirecting. Redirecting uses headers, so it's important not to output any data before sending the headers, because they can't be set once your output has been sent.
Your code is telling the browser to redirect, so that's what I'd expect to happen. What were you expecting to happen?
If you really want to display a message to the user, it would make more sense doing it by displaying a view, and setting a meta redirect.