mirror of
https://github.com/ckolivas/lrzip.git
synced 2026-04-21 06:03:54 +00:00
Fix divide by zero error when a file is smaller than the page size and compressed with -U.
This commit is contained in:
parent
22da2ee76d
commit
f2b5852872
1 changed files with 2 additions and 0 deletions
2
rzip.c
2
rzip.c
|
|
@ -105,6 +105,8 @@ struct sliding_buffer {
|
|||
static void round_to_page(i64 *size)
|
||||
{
|
||||
*size -= *size % control.page_size;
|
||||
if (unlikely(!*size))
|
||||
*size = control.page_size;
|
||||
}
|
||||
|
||||
static void remap_low_sb(void)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue