wayland: guard devices_are_equal completely

Only used if we have drm. Avoids a -Wunused-function error.
This commit is contained in:
Dudemanguy 2024-10-16 16:14:04 -05:00
parent c0f1954d66
commit ca31b94843
1 changed files with 2 additions and 2 deletions

View File

@ -1985,18 +1985,18 @@ static void add_feedback(struct vo_wayland_feedback_pool *fback_pool,
}
}
#if HAVE_DRM
static bool devices_are_equal(dev_t a, dev_t b)
{
bool ret = false;
#if HAVE_DRM
drmDevice *deviceA, *deviceB;
if (!drmGetDeviceFromDevId(a, 0, &deviceA) && !drmGetDeviceFromDevId(b, 0, &deviceB))
ret = drmDevicesEqual(deviceA, deviceB);
drmFreeDevice(&deviceA);
drmFreeDevice(&deviceB);
#endif
return ret;
}
#endif
static void do_minimize(struct vo_wayland_state *wl)
{