зеркало из https://github.com/microsoft/git.git
Merge branch 'mk/diff-delta-avoid-large-offset'
The delta format used in the packfile cannot reference data at offset larger than what can be expressed in 4-byte, but the generator for the data failed to make sure the offset does not overflow. This has been corrected. * mk/diff-delta-avoid-large-offset: diff-delta: do not allow delta offset truncation
This commit is contained in:
Коммит
fdbe2ac198
|
@ -454,6 +454,9 @@ create_delta(const struct delta_index *index,
|
|||
moff += msize;
|
||||
msize = left;
|
||||
|
||||
if (moff > 0xffffffff)
|
||||
msize = 0;
|
||||
|
||||
if (msize < 4096) {
|
||||
int j;
|
||||
val = 0;
|
||||
|
|
Загрузка…
Ссылка в новой задаче