[PATCH] libweston-desktop: Fix some clang warnings
Armin Krezović
krezovic.armin at gmail.com
Sat Sep 10 17:11:21 UTC 2016
Fixes:
implicit conversion from enumeration type '...' to different
enumeration type '...' [-Wenum-conversion]
Signed-off-by: Armin Krezović <krezovic.armin at gmail.com>
---
libweston-desktop/wl-shell.c | 4 +++-
libweston-desktop/xdg-shell-v5.c | 4 +++-
libweston-desktop/xdg-shell-v6.c | 4 +++-
3 files changed, 9 insertions(+), 3 deletions(-)
diff --git a/libweston-desktop/wl-shell.c b/libweston-desktop/wl-shell.c
index 74ce473..97f6e06 100644
--- a/libweston-desktop/wl-shell.c
+++ b/libweston-desktop/wl-shell.c
@@ -231,8 +231,10 @@ weston_desktop_wl_shell_surface_protocol_resize(struct wl_client *wl_client,
struct weston_seat *seat = wl_resource_get_user_data(seat_resource);
struct weston_desktop_wl_shell_surface *surface =
weston_desktop_surface_get_implementation_data(dsurface);
+ enum weston_desktop_surface_edge surf_edges =
+ (enum weston_desktop_surface_edge) edges;
- weston_desktop_api_resize(surface->desktop, dsurface, seat, serial, edges);
+ weston_desktop_api_resize(surface->desktop, dsurface, seat, serial, surf_edges);
}
static void
diff --git a/libweston-desktop/xdg-shell-v5.c b/libweston-desktop/xdg-shell-v5.c
index 83e5d30..ef292a8 100644
--- a/libweston-desktop/xdg-shell-v5.c
+++ b/libweston-desktop/xdg-shell-v5.c
@@ -393,9 +393,11 @@ weston_desktop_xdg_surface_protocol_resize(struct wl_client *wl_client,
wl_resource_get_user_data(seat_resource);
struct weston_desktop_xdg_surface *surface =
weston_desktop_surface_get_implementation_data(dsurface);
+ enum weston_desktop_surface_edge surf_edges =
+ (enum weston_desktop_surface_edge) edges;
weston_desktop_xdg_surface_ensure_added(surface);
- weston_desktop_api_resize(surface->desktop, dsurface, seat, serial, edges);
+ weston_desktop_api_resize(surface->desktop, dsurface, seat, serial, surf_edges);
}
static void
diff --git a/libweston-desktop/xdg-shell-v6.c b/libweston-desktop/xdg-shell-v6.c
index 70e9132..1f9ac94 100644
--- a/libweston-desktop/xdg-shell-v6.c
+++ b/libweston-desktop/xdg-shell-v6.c
@@ -368,9 +368,11 @@ weston_desktop_xdg_toplevel_protocol_resize(struct wl_client *wl_client,
wl_resource_get_user_data(seat_resource);
struct weston_desktop_xdg_toplevel *toplevel =
weston_desktop_surface_get_implementation_data(dsurface);
+ enum weston_desktop_surface_edge surf_edges =
+ (enum weston_desktop_surface_edge) edges;
weston_desktop_api_resize(toplevel->base.desktop,
- dsurface, seat, serial, edges);
+ dsurface, seat, serial, surf_edges);
}
static void
--
2.10.0
More information about the wayland-devel
mailing list