sceVideoOutGetResolutionStatus error behavior (#3044)

This commit is contained in:
Stephen Miller 2025-06-05 14:14:34 -05:00 committed by GitHub
parent 3b3026ff1c
commit 43bf4ed1bc
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -282,7 +282,12 @@ s32 PS4_SYSV_ABI sceVideoOutGetVblankStatus(int handle, SceVideoOutVblankStatus*
s32 PS4_SYSV_ABI sceVideoOutGetResolutionStatus(s32 handle, SceVideoOutResolutionStatus* status) {
LOG_INFO(Lib_VideoOut, "called");
*status = driver->GetPort(handle)->resolution;
auto* port = driver->GetPort(handle);
if (!port || !port->is_open) {
return ORBIS_VIDEO_OUT_ERROR_INVALID_HANDLE;
}
*status = port->resolution;
return ORBIS_OK;
}