diff options
| author | Patrick Steinhardt <ps@pks.im> | 2018-06-29 09:11:02 +0200 |
|---|---|---|
| committer | Patrick Steinhardt <ps@pks.im> | 2018-06-29 09:30:02 +0200 |
| commit | 24597812220325f1cb38f61e56b095ff38d1b1cb (patch) | |
| tree | f1cbcd896bc749ad87c36089b840eb6d85eaacd6 /include/git2/diff.h | |
| parent | 7db258706ab4e09046255cdcbf27c5af8d29a551 (diff) | |
| download | libgit2-24597812220325f1cb38f61e56b095ff38d1b1cb.tar.gz | |
delta: fix out-of-bounds read of delta
When computing the offset and length of the delta base, we repeatedly
increment the `delta` pointer without checking whether we have advanced
past its end already, which can thus result in an out-of-bounds read.
Fix this by repeatedly checking whether we have reached the end. Add a
test which would cause Valgrind to produce an error.
Reported-by: Riccardo Schirone <rschiron@redhat.com>
Test-provided-by: Riccardo Schirone <rschiron@redhat.com>
Diffstat (limited to 'include/git2/diff.h')
0 files changed, 0 insertions, 0 deletions
