diff --git a/src/AdaptiveFileAllocationIterator.h b/src/AdaptiveFileAllocationIterator.h index 7a5cd51d2..637a7cae1 100644 --- a/src/AdaptiveFileAllocationIterator.h +++ b/src/AdaptiveFileAllocationIterator.h @@ -66,7 +66,11 @@ public: virtual off_t getCurrentLength() { - return offset_; + if(allocator_.isNull()) { + return offset_; + } else { + return allocator_->getCurrentLength(); + } } virtual uint64_t getTotalLength()