[vlc-devel] [PATCH 8/8] d3d_dynamic_shader: don't log an error when there is none
Steve Lhomme
robux4 at ycbcr.xyz
Wed Mar 31 06:25:28 UTC 2021
There can be warnings in the pErrBlob.
---
modules/video_output/win32/d3d_dynamic_shader.c | 5 ++++-
1 file changed, 4 insertions(+), 1 deletion(-)
diff --git a/modules/video_output/win32/d3d_dynamic_shader.c b/modules/video_output/win32/d3d_dynamic_shader.c
index e4f73518ed4..f08ff79dedc 100644
--- a/modules/video_output/win32/d3d_dynamic_shader.c
+++ b/modules/video_output/win32/d3d_dynamic_shader.c
@@ -361,7 +361,10 @@ static HRESULT CompileShader(vlc_object_t *obj, const d3d_shader_compiler_t *com
if (FAILED(hr) || pErrBlob) {
const char *err = pErrBlob ? ID3D10Blob_GetBufferPointer(pErrBlob) : NULL;
- msg_Err(obj, "invalid %s Shader (hr=0x%lX): %s", pixelShader?"Pixel":"Vertex", hr, err );
+ if (SUCCEEDED(hr))
+ msg_Dbg(obj, "%s Shader: %s", pixelShader?"Pixel":"Vertex", err );
+ else
+ msg_Err(obj, "invalid %s Shader (hr=0x%lX): %s", pixelShader?"Pixel":"Vertex", hr, err );
if (pErrBlob)
ID3D10Blob_Release(pErrBlob);
if (FAILED(hr))
--
2.29.2
More information about the vlc-devel
mailing list