Implemented sendFileToRemote function to handle possible failure in sending. It will send until done and never ever stop retrying in case of failure.

Signed-off-by: Daniel (dmilith) Dettlaff <dmilith@verknowsys.com>