From 97e0d7646c873ea3badfa604b3f084ed6208af97 Mon Sep 17 00:00:00 2001
From: Wim Taymans <wtaymans@redhat.com>
Date: Tue, 26 Nov 2024 13:37:06 +0100
Subject: [PATCH] pass right types to methods


Upstream-Status: Backport [https://gitlab.freedesktop.org/pipewire/media-session/-/commit/e6243381cf2b7d0d33707627b4186f5580908752]
Signed-off-by: Yoann Congal <yoann.congal@smile.fr>
---
 src/access-flatpak.c | 2 +-
 src/access-portal.c  | 2 +-
 src/default-routes.c | 2 +-
 3 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/src/access-flatpak.c b/src/access-flatpak.c
index afe780b2d..dd802d6eb 100644
--- a/src/access-flatpak.c
+++ b/src/access-flatpak.c
@@ -114,7 +114,7 @@ static void object_update(void *data)
 		pw_log_info("%p: flatpak client %d granted 0x%08x permissions"
 				, impl, client->id, perms);
 		permissions[0] = PW_PERMISSION_INIT(PW_ID_ANY, perms);
-		pw_client_update_permissions(client->obj->obj.proxy,
+		pw_client_update_permissions((struct pw_client*)client->obj->obj.proxy,
 				1, permissions);
 		client->active = true;
 	}
diff --git a/src/access-portal.c b/src/access-portal.c
index 92d95a26b..4e3a9f52a 100644
--- a/src/access-portal.c
+++ b/src/access-portal.c
@@ -265,7 +265,7 @@ set_global_permissions(void *data, struct sm_object *object)
 		permissions[n_permissions++] =
 			PW_PERMISSION_INIT(object->id, allowed ? PW_PERM_ALL : 0);
 		pw_log_info("%p: object %d allowed:%d", impl, object->id, allowed);
-		pw_client_update_permissions(client->obj->obj.proxy,
+		pw_client_update_permissions((struct pw_client*)client->obj->obj.proxy,
 				n_permissions, permissions);
 	}
 	return 0;
diff --git a/src/default-routes.c b/src/default-routes.c
index 5a842faf7..86f9e217b 100644
--- a/src/default-routes.c
+++ b/src/default-routes.c
@@ -479,7 +479,7 @@ static int restore_route_params(struct device *dev, const char *val, const struc
 	if (pw_log_level_enabled(SPA_LOG_LEVEL_DEBUG))
 		spa_debug_pod(2, NULL, param);
 
-	pw_device_set_param((struct pw_node*)dev->obj->obj.proxy,
+	pw_device_set_param((struct pw_device*)dev->obj->obj.proxy,
 			SPA_PARAM_Route, 0, param);
 
 	sm_media_session_schedule_rescan(dev->impl->session);
