added method for sending error packets , issue with receviing packets at
the client.