--- libavfilter/signature_lookup.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/libavfilter/signature_lookup.c b/libavfilter/signature_lookup.c index a0ca818a9b..b39a3e225b 100644 --- a/libavfilter/signature_lookup.c +++ b/libavfilter/signature_lookup.c @@ -128,7 +128,7 @@ static int get_jaccarddist(SignatureContext *sc, CoarseSignature *first, CoarseS int jaccarddist, i, composdist = 0, cwthcount = 0; for (i = 0; i < 5; i++) { if ((jaccarddist = intersection_word(first->data[i], second->data[i])) > 0) { - jaccarddist /= union_word(first->data[i], second->data[i]); + jaccarddist /= FFMAX(union_word(first->data[i], second->data[i]), 1); } if (jaccarddist >= sc->thworddist) { if (++cwthcount > 2) { -- 2.43.2 _______________________________________________ ffmpeg-devel mailing list ffmpeg-devel@ffmpeg.org https://ffmpeg.org/mailman/listinfo/ffmpeg-devel To unsubscribe, visit link above, or email ffmpeg-devel-requ...@ffmpeg.org with subject "unsubscribe".