Fixed bug with sending erroneous packets