xf86drm: Handle unrecognized subsystems safely in drmGetDevice[s]()
authorMatt Roper <matthew.d.roper@intel.com>
Fri, 16 Oct 2015 22:11:24 +0000 (15:11 -0700)
committerEmil Velikov <emil.l.velikov@gmail.com>
Tue, 20 Oct 2015 17:45:23 +0000 (18:45 +0100)
commitba5a6ecf81fc2e25a4c7b8c592143faadfdd63db
treea322dcb35f1de1ea1a8bf52130d1e60f8798ddd8
parentcf0f036e3d819fb7894562bfdfea95e5e5f57219
xf86drm: Handle unrecognized subsystems safely in drmGetDevice[s]()

Both drmGetDevice() and drmGetDevices() currently print a warning when
they encounter an unknown (non-PCI) subsystem type for a device node,
but they still proceed to assume that the drmDevicePtr was initialized
and try to add it to the local device array.  Add a 'continue' to the
error case handling to bypass the rest of the processing for devices we
can't handle.

Signed-off-by: Matt Roper <matthew.d.roper@intel.com>
Reviewed-by: Alex Deucher <alexander.deucher@amd.com>
Reviewed-by: Emil Velikov <emil.l.velikov@gmail.com>
xf86drm.c