Skip to content

Commit 0a8745f

Browse files
committed
diff: assert that we're passed a valid git_diff object
CID 1386176, 1386177, 1388219
1 parent 9c23552 commit 0a8745f

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

src/diff_tform.c

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -816,6 +816,8 @@ int git_diff_find_similar(
816816
diff_find_match *best_match;
817817
git_diff_file swap;
818818

819+
assert(diff);
820+
819821
if ((error = normalize_find_opts(diff, &opts, given_opts)) < 0)
820822
return error;
821823

0 commit comments

Comments
 (0)