uvcsink: configfs.c: fix globing in uvc_video_device

The gadget in the sysfs can be postfixed with an index.
Fix the globbing by adding a wildcard after /gadget*/.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/1304>
This commit is contained in:
Michael Grzeschik 2023-05-09 00:50:41 +02:00 committed by GStreamer Marge Bot
parent 38aa1fc414
commit fd3a6ce642

View file

@ -234,7 +234,7 @@ udc_find_video_device (const char *udc, const char *function)
int ret;
ret = asprintf (&vpath,
"/sys/class/udc/%s/device/gadget/video4linux/video*", udc ? udc : "*");
"/sys/class/udc/%s/device/gadget*/video4linux/video*", udc ? udc : "*");
if (!ret)
return NULL;