Fails CCD initialisation if get_config_buffers detect WDDM is not present

There's no point continuing without WDDM as CCD cannot work without it.

Signed-off-by: Frediano Ziglio <fziglio@redhat.com>
Acked-by: Sameeh Jubran <sameeh@daynix.com>
This commit is contained in:
Frediano Ziglio 2016-09-01 12:53:04 +01:00
parent 67b63fe6f7
commit b24a935335

View File

@ -843,6 +843,10 @@ bool CCD::get_config_buffers()
LONG error(ERROR_SUCCESS);
error = _pfnGetDisplayConfigBufferSizes(QDC_ALL_PATHS, &_numPathElements,
&_numModeElements);
if (error == ERROR_NOT_SUPPORTED) {
vd_printf("GetDisplayConfigBufferSizes failed, missing WDDM");
throw std::exception();
}
if (error) {
vd_printf("GetDisplayConfigBufferSizes failed with 0x%lx", error);
return false;