If you are getting this error it's probably because you have one or more echo statments on your .bashrc or .bash_profile files (like we did here - customizing your bash shell with a welcome message or your nic's ips).
Well, i found this script (here), and it allows to verify if a shell is a login shell or not and if it is (i.e. vsftp) all we need to do is not to echo anything. It's not perfect but it's the better solution I could find (let me know if you have a better one).
Here's the end result: