On Sat, Mar 17 2018, Nguyễn Thái Ngọc Duy jotted:

> Because of struct packing from now on we can only handle max depth
> 4095
> [...]
> +     if (depth >= (1 << OE_DEPTH_BITS))
> +             die(_("delta chain depth %d is greater than maximum limit %d"),
> +                 depth, (1 << OE_DEPTH_BITS));
> +

This has a off-by-one error:

    $ git repack --depth=4096
    fatal: delta chain depth 4096 is greater than maximum limit 4096

Per the check we should be feeding `(1 << OE_DEPTH_BITS) - 1` to die().

Reply via email to