aboutsummaryrefslogtreecommitdiffstats
path: root/src/lib/utils/data_src.cpp
diff options
context:
space:
mode:
authorJack Lloyd <[email protected]>2015-12-31 11:14:50 -0500
committerJack Lloyd <[email protected]>2015-12-31 11:14:50 -0500
commit75e60b8fdbce20c5a82cd09c741b0cad5c25547b (patch)
tree2677fe47c7db57c49f92d9dcbb6d82125299bd1a /src/lib/utils/data_src.cpp
parentd4915aa4cd9c11879780267413f2980d0014240e (diff)
Add missing assignment in DataSource::discard_next
Reported on the mailing list by Falko
Diffstat (limited to 'src/lib/utils/data_src.cpp')
-rw-r--r--src/lib/utils/data_src.cpp1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/lib/utils/data_src.cpp b/src/lib/utils/data_src.cpp
index 4e0725943..b79f83d40 100644
--- a/src/lib/utils/data_src.cpp
+++ b/src/lib/utils/data_src.cpp
@@ -41,6 +41,7 @@ size_t DataSource::discard_next(size_t n)
{
const size_t got = this->read(buf, std::min(n, sizeof(buf)));
discarded += got;
+ n -= got;
if(got == 0)
break;