From b3b3f2f39c734c8f688e8bc9f34d7749d8cb4140 Mon Sep 17 00:00:00 2001 From: Ron Pedde Date: Thu, 29 Jun 2006 06:37:28 +0000 Subject: [PATCH] Suppress errors when dep libs aren't present (wmvcore.dll for ssc-wma, for example). Should close ticket #177 --- src/os-win32.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/os-win32.c b/src/os-win32.c index 07d45db4..e85fe5ab 100644 --- a/src/os-win32.c +++ b/src/os-win32.c @@ -702,11 +702,14 @@ void _os_unlock(void) { */ void *os_loadlib(char **pe, char *path) { void *retval; + UINT old_mode; + old_mode = SetErrorMode(SEM_NOOPENFILEERRORBOX); retval = (void*)LoadLibrary(path); if(!retval) { if(pe) *pe = strdup(os_strerror(0)); } + SetErrorMode(old_mode); return retval; }