Retry file sending on connection loss