From c874d25ee37fb159f3490734a84ea2c20480259a Mon Sep 17 00:00:00 2001 From: Ryan Pavlik Date: Fri, 16 Aug 2019 17:00:31 -0500 Subject: [PATCH] st/prober: Fix null dereference. Found by clang-tidy. --- src/xrt/state_trackers/prober/p_libuvc.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/xrt/state_trackers/prober/p_libuvc.c b/src/xrt/state_trackers/prober/p_libuvc.c index 70030e9e6..256e41aec 100644 --- a/src/xrt/state_trackers/prober/p_libuvc.c +++ b/src/xrt/state_trackers/prober/p_libuvc.c @@ -52,7 +52,7 @@ p_libuvc_probe(struct prober* p) P_ERROR(p, "\tFailed to enumerate uvc devices\n"); return -1; } - + p->uvc.count = 0; // Count the number of UVC devices. while (p->uvc.list != NULL && p->uvc.list[p->uvc.count] != NULL) { p->uvc.count++;