diff --git a/client/net_xfer.C b/client/net_xfer.C index 25668a7b62..30893ae598 100644 --- a/client/net_xfer.C +++ b/client/net_xfer.C @@ -143,6 +143,7 @@ void NET_XFER::init(char* host, int p, int b) { strcpy(hostname, host); port = p; blocksize = b; + nbytes_xfered = 0; } // Insert a NET_XFER object into the set @@ -265,6 +266,7 @@ int NET_XFER_SET::do_select(int max_bytes, int& bytes_transferred) { } else if (nxp->do_file_io) { if (max_bytes > 0) { retval = nxp->do_xfer(n); + nxp->nbytes_xfered += n; max_bytes -= n; bytes_transferred += n; } diff --git a/client/net_xfer.h b/client/net_xfer.h index ce13bdf800..e60e07a664 100644 --- a/client/net_xfer.h +++ b/client/net_xfer.h @@ -48,6 +48,7 @@ public: char hostname[256]; int port; int blocksize; + int nbytes_xfered; // total number of bytes transferred void init(char* host, int port, int blocksize); int open_server();