green-coder / cdc

A library for performing Content-Defined Chunking (CDC) on data streams.
MIT License
23 stars 5 forks source link

Fix for a short iterator in `reset_and_prefill_window` #5

Open Dr-Emann opened 2 years ago

Dr-Emann commented 2 years ago

In the case the iterator provided to reset_and_prefill_window was shorter than window_size - 1, the window would not be fully reset, and future slides will shift out previous data, and return incorrect hashes.