History

avfilter/vf_v360: fix possible out of range values

Paul B Mahol committed 6 years ago

Commit 3a035a81 parent eaba6ce1 file · +3 −3Browse files

Showing the changes to libavfilter (1 of 1 file). Show all

Unified · Split

libavfilter/vf_v360.c+3−3
@@ -763,12 +763,12 @@ static inline int mod(int a, int b) · 762 unmodified lines
763763 static inline int reflecty(int y, int h)
764764 {
765765 if (y < 0) {
766− return -y;
766+ y = -y;
767767 } else if (y >= h) {
768− return 2 * h - 1 - y;
768+ y = 2 * h - 1 - y;
769769 }
770770
771− return y;
771+ return av_clip(y, 0, h - 1);
772772 }
773773
774774 /**

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t