From: Andreas Färber Date: Thu, 23 Jun 2011 14:24:46 +0000 (+0200) Subject: coreaudio: Avoid formatting UInt32 type X-Git-Tag: qemu-xen-4.3.0-rc1~2658 X-Git-Url: http://xenbits.xensource.com/gitweb?a=commitdiff_plain;h=cbc36cb05d56bc510e85d14059ee0ae2ae6e3126;p=qemu-upstream-4.5-testing.git coreaudio: Avoid formatting UInt32 type coreaudioVoiceOut's audioDevicePropertyBufferFrameSize is defined as UInt32 and is being used by reference for AudioDevice{Get,Set}Property(). UInt32 is unsigned int on __LP64__ but unsigned long otherwise. Cast to POSIX type and use PRIu32 format specifier to hide the details. This avoids a warning on ppc64. Cc: malc Signed-off-by: Andreas Faerber Signed-off-by: malc --- diff --git a/audio/coreaudio.c b/audio/coreaudio.c index 3bd75cdda..0c6f1ef60 100644 --- a/audio/coreaudio.c +++ b/audio/coreaudio.c @@ -360,8 +360,8 @@ static int coreaudio_init_out (HWVoiceOut *hw, struct audsettings *as) &core->audioDevicePropertyBufferFrameSize); if (status != kAudioHardwareNoError) { coreaudio_logerr2 (status, typ, - "Could not set device buffer frame size %ld\n", - core->audioDevicePropertyBufferFrameSize); + "Could not set device buffer frame size %" PRIu32 "\n", + (uint32_t)core->audioDevicePropertyBufferFrameSize); return -1; }