This is an automated email from the git hooks/post-receive script.

Git pushed a commit to branch master
in repository ffmpeg.

The following commit(s) were added to refs/heads/master by this push:
     new 89909a18c1 avfilter/vf_huesaturation: skip the luminance shear when 
the luminance vector is zero
89909a18c1 is described below

commit 89909a18c1cd7d17bb48a03e1d73fdb53d5d7ff1
Author:     zhang xingxing <[email protected]>
AuthorDate: Mon Sep 21 06:10:49 2026 +0200
Commit:     michaelni <[email protected]>
CommitDate: Mon Sep 28 03:45:08 2026 +0000

    avfilter/vf_huesaturation: skip the luminance shear when the luminance 
vector is zero
    
    Found-by: zhang xingxing
    Fixes: float division by 0
    Fixes: WgQdanA8nq8x
    Fixes: swarm-Division-by-zero-in-hue-rotation-with-zero-weights-bda2e7
---
 libavfilter/vf_huesaturation.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/libavfilter/vf_huesaturation.c b/libavfilter/vf_huesaturation.c
index 6a4aadeee1..6fdb39bafb 100644
--- a/libavfilter/vf_huesaturation.c
+++ b/libavfilter/vf_huesaturation.c
@@ -321,8 +321,8 @@ static void hue_rotate_matrix(float matrix[4][4], float 
rotation,
     y_rotate_matrix(matrix, yrs, yrc);
 
     transform_point(matrix, rlw, glw, blw, &lx, &ly, &lz);
-    zsx = lx / lz;
-    zsy = ly / lz;
+    zsx = lz ? lx / lz : 0.f;
+    zsy = lz ? ly / lz : 0.f;
     z_shear_matrix(matrix, zsx, zsy);
 
     zrs = sinf(rotation * M_PI / 180.f);

-- 
To stop receiving notification emails like this one, please contact
[email protected].
_______________________________________________
ffmpeg-cvslog mailing list -- [email protected]
To unsubscribe send an email to [email protected]

Reply via email to