[MPlayer-cygwin] mingw compile/mplayer binary codecs question

Joey Parrish joey at nicewarrior.org
Sun Mar 7 08:10:32 CET 2004


On Sat, Mar 06, 2004 at 01:22:39AM -0500, Compn wrote:
> but, the error message is not clear, can you devs fix it?
> (i know this requires lots of rewrite code, just a suggestion)
> instead of "error loading dll" how about "dll not found" or
> "cannot find dll in dir c:/blah" or "dll is incorrect version" or 
> "dll returned error" or "dll will not work on this os" or return
> an "dll error code 15" and list the codes in the man/docs

If LoadLibrary fails, then I think this may work (untested):

 char **buf = NULL;
 int flags = FORMAT_MESSAGE_ALLOCATE_BUFFER | FORMAT_MESSAGE_FROM_SYSTEM | FORMAT_MESSAGE_IGNORE_INSERTS;
 if (FormatMessage(flags, NULL, GetLastError(), 0, &buf, 0, NULL)) {
   printf("%s\n", *buf);
 }

--Joey

-- 
"Living in the complex world of the future is somewhat
like having bees live in your head.  But, there they are."




More information about the MPlayer-cygwin mailing list