Message ID | 1308839086-29122-1-git-send-email-andreas.faerber@web.de |
---|---|
State | New |
Headers | show |
On Thu, 23 Jun 2011, Andreas F?rber wrote: > OSStatus type is defined as SInt32. That's signed int on __LP64__ and > signed long otherwise. > Since it is an explicit 32-bit-width type, cast to corresponsing POSIX type > and use PRId32 format specifier. This avoids a warning on ppc64. > [..snip..] Applied thanks (ditto UInt32 patch).
Sorry for the delay. Commit 744d3644181ddb16ef5944a0f9217e46961c8c84 works fine on OSX 10.6. Alexandre On Thu, Jun 23, 2011 at 10:58 AM, malc <av1474@comtv.ru> wrote: > On Thu, 23 Jun 2011, Andreas F?rber wrote: > >> OSStatus type is defined as SInt32. That's signed int on __LP64__ and >> signed long otherwise. >> Since it is an explicit 32-bit-width type, cast to corresponsing POSIX type >> and use PRId32 format specifier. This avoids a warning on ppc64. >> > > [..snip..] > > Applied thanks (ditto UInt32 patch). > > -- > mailto:av1474@comtv.ru >
diff --git a/audio/coreaudio.c b/audio/coreaudio.c index 3bd75cd..508bcbe 100644 --- a/audio/coreaudio.c +++ b/audio/coreaudio.c @@ -104,7 +104,7 @@ static void coreaudio_logstatus (OSStatus status) break; default: - AUD_log (AUDIO_CAP, "Reason: status code %ld\n", status); + AUD_log (AUDIO_CAP, "Reason: status code %" PRId32 "\n", (int32_t)status); return; }
OSStatus type is defined as SInt32. That's signed int on __LP64__ and signed long otherwise. Since it is an explicit 32-bit-width type, cast to corresponsing POSIX type and use PRId32 format specifier. This avoids a warning on ppc64. Cc: malc <av1474@comtv.ru> Signed-off-by: Andreas Faerber <andreas.faerber@web.de> --- audio/coreaudio.c | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-)