Unverified Commit e9b2e434 by Edward Thomson Committed by GitHub

Merge pull request #4761 from pks-t/pks/aix-diff-oom

diff: fix OOM on AIX when finding similar deltas in empty diff
parents 9275d84c c65568d8
......@@ -822,7 +822,7 @@ int git_diff_find_similar(
num_deltas = diff->deltas.length;
/* TODO: maybe abort if deltas.length > rename_limit ??? */
if (!git__is_uint32(num_deltas))
if (!num_deltas || !git__is_uint32(num_deltas))
goto cleanup;
/* No flags set; nothing to do */
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment