ErrorHandler is called when the packet can't be delivered.

- Add error as parameter