[vlc-devel] [PATCH v2] display: fix a few warnings
Johan Gunnarsson
johan.gunnarsson at gmail.com
Wed Jan 16 22:07:33 CET 2019
video_output/display.c: In function ‘vout_display_TranslateMouseState’:
video_output/display.c:262:23: warning: ‘y’ may be used uninitialized in this function [-Wmaybe-uninitialized]
+ (int64_t)(y - place.y) * vd->source.i_visible_height / place.height;
~~~^~~~~~~~~~
video_output/display.c:260:23: warning: ‘x’ may be used uninitialized in this function [-Wmaybe-uninitialized]
+ (int64_t)(x - place.x) * vd->source.i_visible_width / place.width;
~~~^~~~~~~~~~
---
src/video_output/display.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/src/video_output/display.c b/src/video_output/display.c
index be744e0b98..0b34e8277f 100644
--- a/src/video_output/display.c
+++ b/src/video_output/display.c
@@ -254,6 +254,8 @@ void vout_display_TranslateMouseState(vout_display_t *vd, vlc_mouse_t *video,
x = place.height - wy;
y = place.width - wx;
break;
+ default:
+ vlc_assert_unreachable();
}
video->i_x = vd->source.i_x_offset
--
2.17.1
More information about the vlc-devel
mailing list