Jörg Höhle : winecoreaudio: OSStatus is not necessarily a FOURCC.
Alexandre Julliard
julliard at winehq.org
Mon Nov 15 13:28:55 CST 2010
Module: wine
Branch: master
Commit: 2e54019391572d354d9a3295ee941df3cb536897
URL: http://source.winehq.org/git/wine.git/?a=commit;h=2e54019391572d354d9a3295ee941df3cb536897
Author: Jörg Höhle <hoehle at users.sourceforge.net>
Date: Sat Nov 13 18:05:18 2010 +0100
winecoreaudio: OSStatus is not necessarily a FOURCC.
---
dlls/winecoreaudio.drv/coreaudio.h | 5 ++++-
1 files changed, 4 insertions(+), 1 deletions(-)
diff --git a/dlls/winecoreaudio.drv/coreaudio.h b/dlls/winecoreaudio.drv/coreaudio.h
index 4cf2b03..68b5250 100644
--- a/dlls/winecoreaudio.drv/coreaudio.h
+++ b/dlls/winecoreaudio.drv/coreaudio.h
@@ -32,10 +32,13 @@ extern LONG CoreAudio_MixerInit(void);
extern void CoreAudio_MixerRelease(void);
/* fourcc is in native order, where MSB is the first character. */
-static inline const char* wine_dbgstr_fourcc(unsigned long fourcc)
+static inline const char* wine_dbgstr_fourcc(INT32 fourcc)
{
char buf[4] = { (char) (fourcc >> 24), (char) (fourcc >> 16),
(char) (fourcc >> 8), (char) fourcc };
+ /* OSStatus is a signed decimal except in parts of CoreAudio */
+ if ((buf[0] < 32) || (buf[1] < 32) || (buf[2] < 32) || (buf[3] < 32))
+ return wine_dbg_sprintf("%d", fourcc);
return wine_dbgstr_an(buf, sizeof(buf));
}
More information about the wine-cvs
mailing list