Signed-off-by: Eric Pouech eric.pouech@gmail.com
--- dlls/winealsa.drv/alsa.c | 4 ++-- dlls/winealsa.drv/mmdevdrv.c | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-)
diff --git a/dlls/winealsa.drv/alsa.c b/dlls/winealsa.drv/alsa.c index 8b6a87aa864c..33b405a884cf 100644 --- a/dlls/winealsa.drv/alsa.c +++ b/dlls/winealsa.drv/alsa.c @@ -637,7 +637,7 @@ static snd_pcm_format_t alsa_format(const WAVEFORMATEX *fmt) return format; }
-static int alsa_channel_index(DWORD flag) +static int alsa_channel_index(UINT flag) { switch(flag){ case SPEAKER_FRONT_LEFT: @@ -702,7 +702,7 @@ static HRESULT map_channels(EDataFlow flow, const WAVEFORMATEX *fmt, int *alsa_c
if(flow != eCapture && (fmt->wFormatTag == WAVE_FORMAT_EXTENSIBLE || fmt->nChannels > 2) ){ WAVEFORMATEXTENSIBLE *fmtex = (void*)fmt; - DWORD mask, flag = SPEAKER_FRONT_LEFT; + UINT mask, flag = SPEAKER_FRONT_LEFT; UINT i = 0;
if(fmt->wFormatTag == WAVE_FORMAT_EXTENSIBLE && diff --git a/dlls/winealsa.drv/mmdevdrv.c b/dlls/winealsa.drv/mmdevdrv.c index 1a99f0ac26c9..855fb68f457a 100644 --- a/dlls/winealsa.drv/mmdevdrv.c +++ b/dlls/winealsa.drv/mmdevdrv.c @@ -1363,7 +1363,7 @@ static HRESULT WINAPI AudioCaptureClient_GetBuffer(IAudioCaptureClient *iface, params.stream = This->stream; params.data = data; params.frames = frames; - params.flags = flags; + params.flags = (UINT32*)flags; params.devpos = devpos; params.qpcpos = qpcpos;
Signed-off-by: Eric Pouech eric.pouech@gmail.com
--- dlls/winealsa.drv/Makefile.in | 1 - dlls/winealsa.drv/alsa.c | 8 ++++---- dlls/winealsa.drv/alsamidi.c | 6 +++--- dlls/winealsa.drv/midi.c | 6 +++--- dlls/winealsa.drv/mmdevdrv.c | 40 ++++++++++++++++++++-------------------- 5 files changed, 30 insertions(+), 31 deletions(-)
diff --git a/dlls/winealsa.drv/Makefile.in b/dlls/winealsa.drv/Makefile.in index 1349f6f9dab5..1110729a352e 100644 --- a/dlls/winealsa.drv/Makefile.in +++ b/dlls/winealsa.drv/Makefile.in @@ -1,4 +1,3 @@ -EXTRADEFS = -DWINE_NO_LONG_TYPES MODULE = winealsa.drv UNIXLIB = winealsa.so IMPORTS = uuid ole32 advapi32 diff --git a/dlls/winealsa.drv/alsa.c b/dlls/winealsa.drv/alsa.c index 33b405a884cf..b91606603a22 100644 --- a/dlls/winealsa.drv/alsa.c +++ b/dlls/winealsa.drv/alsa.c @@ -123,10 +123,10 @@ static HKEY open_hkcu(void)
sid = ((TOKEN_USER *)sid_data)->User.Sid; len = sprintf( buffer, "\Registry\User\S-%u-%u", sid->Revision, - MAKELONG( MAKEWORD( sid->IdentifierAuthority.Value[5], sid->IdentifierAuthority.Value[4] ), - MAKEWORD( sid->IdentifierAuthority.Value[3], sid->IdentifierAuthority.Value[2] ))); + (unsigned)MAKELONG( MAKEWORD( sid->IdentifierAuthority.Value[5], sid->IdentifierAuthority.Value[4] ), + MAKEWORD( sid->IdentifierAuthority.Value[3], sid->IdentifierAuthority.Value[2] ))); for (i = 0; i < sid->SubAuthorityCount; i++) - len += sprintf( buffer + len, "-%u", sid->SubAuthority[i] ); + len += sprintf( buffer + len, "-%u", (unsigned)sid->SubAuthority[i] ); ascii_to_unicode( bufferW, buffer, len + 1 );
return reg_open_key( NULL, bufferW, len * sizeof(WCHAR) ); @@ -2431,7 +2431,7 @@ static NTSTATUS get_prop_value(void *args) return STATUS_SUCCESS; }
- TRACE("Unimplemented property %s,%u\n", wine_dbgstr_guid(&prop->fmtid), prop->pid); + TRACE("Unimplemented property %s,%u\n", wine_dbgstr_guid(&prop->fmtid), (unsigned)prop->pid);
params->result = E_NOTIMPL; return STATUS_SUCCESS; diff --git a/dlls/winealsa.drv/alsamidi.c b/dlls/winealsa.drv/alsamidi.c index c09547cdcf0d..12a469533d90 100644 --- a/dlls/winealsa.drv/alsamidi.c +++ b/dlls/winealsa.drv/alsamidi.c @@ -359,7 +359,7 @@ static void port_add(snd_seq_client_info_t* cinfo, snd_seq_port_info_t* pinfo, u num_dests, wine_dbgstr_w(dest->caps.szPname), dest->caps.wTechnology, dest->caps.wVoices, dest->caps.wNotes, - dest->caps.wChannelMask, dest->caps.dwSupport, + dest->caps.wChannelMask, (unsigned)dest->caps.dwSupport, type);
num_dests++; @@ -407,7 +407,7 @@ static void port_add(snd_seq_client_info_t* cinfo, snd_seq_port_info_t* pinfo, u
TRACE("MidiIn [%d]\tname='%s' support=%d\n" "\tALSA info: midi dev-type=%x, capa=0\n", - num_srcs, wine_dbgstr_w(src->caps.szPname), src->caps.dwSupport, type); + num_srcs, wine_dbgstr_w(src->caps.szPname), (unsigned)src->caps.dwSupport, type);
num_srcs++; } @@ -810,7 +810,7 @@ static UINT midi_out_long_data(WORD dev_id, MIDIHDR *hdr, UINT hdr_size, struct new_data = malloc(hdr->dwBufferLength + 2); }
- TRACE("dwBufferLength=%u !\n", hdr->dwBufferLength); + TRACE("dwBufferLength=%u !\n", (unsigned)hdr->dwBufferLength); TRACE(" %02X %02X %02X ... %02X %02X %02X\n", data[0], data[1], data[2], data[hdr->dwBufferLength-3], data[hdr->dwBufferLength-2], data[hdr->dwBufferLength-1]); diff --git a/dlls/winealsa.drv/midi.c b/dlls/winealsa.drv/midi.c index fc2205de6f6d..81d8312d2371 100644 --- a/dlls/winealsa.drv/midi.c +++ b/dlls/winealsa.drv/midi.c @@ -40,7 +40,7 @@ WINE_DEFAULT_DEBUG_CHANNEL(midi);
static void notify_client(struct notify_context *notify) { - TRACE("dev_id = %d msg = %d param1 = %04lX param2 = %04lX\n", notify->dev_id, notify->msg, notify->param_1, notify->param_2); + TRACE("dev_id = %d msg = %d param1 = %04IX param2 = %04IX\n", notify->dev_id, notify->msg, notify->param_1, notify->param_2);
DriverCallback(notify->callback, notify->flags, notify->device, notify->msg, notify->instance, notify->param_1, notify->param_2); @@ -60,7 +60,7 @@ DWORD WINAPI ALSA_midMessage(UINT wDevID, UINT wMsg, DWORD_PTR dwUser, struct notify_context notify; UINT err;
- TRACE("(%04X, %04X, %08lX, %08lX, %08lX);\n", + TRACE("(%04X, %04X, %08IX, %08IX, %08IX);\n", wDevID, wMsg, dwUser, dwParam1, dwParam2);
params.dev_id = wDevID; @@ -90,7 +90,7 @@ DWORD WINAPI ALSA_modMessage(UINT wDevID, UINT wMsg, DWORD_PTR dwUser, struct notify_context notify; UINT err;
- TRACE("(%04X, %04X, %08lX, %08lX, %08lX);\n", + TRACE("(%04X, %04X, %08IX, %08IX, %08IX);\n", wDevID, wMsg, dwUser, dwParam1, dwParam2);
params.dev_id = wDevID; diff --git a/dlls/winealsa.drv/mmdevdrv.c b/dlls/winealsa.drv/mmdevdrv.c index 855fb68f457a..a3b97adf8c8e 100644 --- a/dlls/winealsa.drv/mmdevdrv.c +++ b/dlls/winealsa.drv/mmdevdrv.c @@ -264,7 +264,7 @@ static void set_device_guid(EDataFlow flow, HKEY drv_key, const WCHAR *key_name, lr = RegCreateKeyExW(HKEY_CURRENT_USER, drv_key_devicesW, 0, NULL, 0, KEY_WRITE, NULL, &drv_key, NULL); if(lr != ERROR_SUCCESS){ - ERR("RegCreateKeyEx(drv_key) failed: %u\n", lr); + ERR("RegCreateKeyEx(drv_key) failed: %lu\n", lr); return; } opened = TRUE; @@ -273,14 +273,14 @@ static void set_device_guid(EDataFlow flow, HKEY drv_key, const WCHAR *key_name, lr = RegCreateKeyExW(drv_key, key_name, 0, NULL, 0, KEY_WRITE, NULL, &key, NULL); if(lr != ERROR_SUCCESS){ - ERR("RegCreateKeyEx(%s) failed: %u\n", wine_dbgstr_w(key_name), lr); + ERR("RegCreateKeyEx(%s) failed: %lu\n", wine_dbgstr_w(key_name), lr); goto exit; }
lr = RegSetValueExW(key, guidW, 0, REG_BINARY, (BYTE*)guid, sizeof(GUID)); if(lr != ERROR_SUCCESS) - ERR("RegSetValueEx(%s\guid) failed: %u\n", wine_dbgstr_w(key_name), lr); + ERR("RegSetValueEx(%s\guid) failed: %lu\n", wine_dbgstr_w(key_name), lr);
RegCloseKey(key); exit: @@ -310,7 +310,7 @@ static void get_device_guid(EDataFlow flow, const char *device, GUID *guid) RegCloseKey(key); return; } - ERR("Invalid type for device %s GUID: %u; ignoring and overwriting\n", + ERR("Invalid type for device %s GUID: %lu; ignoring and overwriting\n", wine_dbgstr_w(key_name), type); } RegCloseKey(dev_key); @@ -535,7 +535,7 @@ static ULONG WINAPI AudioClient_AddRef(IAudioClient3 *iface) ACImpl *This = impl_from_IAudioClient3(iface); ULONG ref; ref = InterlockedIncrement(&This->ref); - TRACE("(%p) Refcount now %u\n", This, ref); + TRACE("(%p) Refcount now %lu\n", This, ref); return ref; }
@@ -545,7 +545,7 @@ static ULONG WINAPI AudioClient_Release(IAudioClient3 *iface) ULONG ref;
ref = InterlockedDecrement(&This->ref); - TRACE("(%p) Refcount now %u\n", This, ref); + TRACE("(%p) Refcount now %lu\n", This, ref); if(!ref){ IAudioClient3_Stop(iface); IMMDevice_Release(This->parent); @@ -583,15 +583,15 @@ static void dump_fmt(const WAVEFORMATEX *fmt) TRACE(")\n");
TRACE("nChannels: %u\n", fmt->nChannels); - TRACE("nSamplesPerSec: %u\n", fmt->nSamplesPerSec); - TRACE("nAvgBytesPerSec: %u\n", fmt->nAvgBytesPerSec); + TRACE("nSamplesPerSec: %lu\n", fmt->nSamplesPerSec); + TRACE("nAvgBytesPerSec: %lu\n", fmt->nAvgBytesPerSec); TRACE("nBlockAlign: %u\n", fmt->nBlockAlign); TRACE("wBitsPerSample: %u\n", fmt->wBitsPerSample); TRACE("cbSize: %u\n", fmt->cbSize);
if(fmt->wFormatTag == WAVE_FORMAT_EXTENSIBLE){ WAVEFORMATEXTENSIBLE *fmtex = (void*)fmt; - TRACE("dwChannelMask: %08x\n", fmtex->dwChannelMask); + TRACE("dwChannelMask: %08lx\n", fmtex->dwChannelMask); TRACE("Samples: %04x\n", fmtex->Samples.wReserved); TRACE("SubFormat: %s\n", wine_dbgstr_guid(&fmtex->SubFormat)); } @@ -686,7 +686,7 @@ static HRESULT WINAPI AudioClient_Initialize(IAudioClient3 *iface, stream_handle stream; unsigned int i;
- TRACE("(%p)->(%x, %x, %s, %s, %p, %s)\n", This, mode, flags, + TRACE("(%p)->(%x, %lx, %s, %s, %p, %s)\n", This, mode, flags, wine_dbgstr_longlong(duration), wine_dbgstr_longlong(period), fmt, debugstr_guid(sessionguid));
if(!fmt) @@ -705,7 +705,7 @@ static HRESULT WINAPI AudioClient_Initialize(IAudioClient3 *iface, AUDCLNT_SESSIONFLAGS_DISPLAY_HIDEWHENEXPIRED | AUDCLNT_STREAMFLAGS_SRC_DEFAULT_QUALITY | AUDCLNT_STREAMFLAGS_AUTOCONVERTPCM)){ - FIXME("Unknown flags: %08x\n", flags); + FIXME("Unknown flags: %08lx\n", flags); return E_INVALIDARG; }
@@ -1192,7 +1192,7 @@ static HRESULT WINAPI AudioClient_InitializeSharedAudioStream(IAudioClient3 *ifa { ACImpl *This = impl_from_IAudioClient3(iface);
- FIXME("(%p)->(0x%x, %u, %p, %s)\n", This, flags, period_frames, format, debugstr_guid(session_guid)); + FIXME("(%p)->(0x%lx, %u, %p, %s)\n", This, flags, period_frames, format, debugstr_guid(session_guid));
return E_NOTIMPL; } @@ -1286,7 +1286,7 @@ static HRESULT WINAPI AudioRenderClient_ReleaseBuffer( ACImpl *This = impl_from_IAudioRenderClient(iface); struct release_render_buffer_params params;
- TRACE("(%p)->(%u, %x)\n", This, written_frames, flags); + TRACE("(%p)->(%u, %lx)\n", This, written_frames, flags);
params.stream = This->stream; params.written_frames = written_frames; @@ -1601,7 +1601,7 @@ static ULONG WINAPI AudioSessionControl_AddRef(IAudioSessionControl2 *iface) AudioSessionWrapper *This = impl_from_IAudioSessionControl2(iface); ULONG ref; ref = InterlockedIncrement(&This->ref); - TRACE("(%p) Refcount now %u\n", This, ref); + TRACE("(%p) Refcount now %lu\n", This, ref); return ref; }
@@ -1610,7 +1610,7 @@ static ULONG WINAPI AudioSessionControl_Release(IAudioSessionControl2 *iface) AudioSessionWrapper *This = impl_from_IAudioSessionControl2(iface); ULONG ref; ref = InterlockedDecrement(&This->ref); - TRACE("(%p) Refcount now %u\n", This, ref); + TRACE("(%p) Refcount now %lu\n", This, ref); if(!ref){ if(This->client){ EnterCriticalSection(&g_sessions_lock); @@ -2297,7 +2297,7 @@ static ULONG WINAPI AudioSessionManager_AddRef(IAudioSessionManager2 *iface) SessionMgr *This = impl_from_IAudioSessionManager2(iface); ULONG ref; ref = InterlockedIncrement(&This->ref); - TRACE("(%p) Refcount now %u\n", This, ref); + TRACE("(%p) Refcount now %lu\n", This, ref); return ref; }
@@ -2306,7 +2306,7 @@ static ULONG WINAPI AudioSessionManager_Release(IAudioSessionManager2 *iface) SessionMgr *This = impl_from_IAudioSessionManager2(iface); ULONG ref; ref = InterlockedDecrement(&This->ref); - TRACE("(%p) Refcount now %u\n", This, ref); + TRACE("(%p) Refcount now %lu\n", This, ref); if(!ref) HeapFree(GetProcessHeap(), 0, This); return ref; @@ -2321,7 +2321,7 @@ static HRESULT WINAPI AudioSessionManager_GetAudioSessionControl( AudioSessionWrapper *wrapper; HRESULT hr;
- TRACE("(%p)->(%s, %x, %p)\n", This, debugstr_guid(session_guid), + TRACE("(%p)->(%s, %lx, %p)\n", This, debugstr_guid(session_guid), flags, out);
hr = get_audio_session(session_guid, This->device, 0, &session); @@ -2348,7 +2348,7 @@ static HRESULT WINAPI AudioSessionManager_GetSimpleAudioVolume( AudioSessionWrapper *wrapper; HRESULT hr;
- TRACE("(%p)->(%s, %x, %p)\n", This, debugstr_guid(session_guid), + TRACE("(%p)->(%s, %lx, %p)\n", This, debugstr_guid(session_guid), flags, out);
hr = get_audio_session(session_guid, This->device, 0, &session); @@ -2447,7 +2447,7 @@ HRESULT WINAPI AUDDRV_GetPropValue(GUID *guid, const PROPERTYKEY *prop, PROPVARI EDataFlow flow; unsigned int size = 0;
- TRACE("%s, (%s,%u), %p\n", wine_dbgstr_guid(guid), wine_dbgstr_guid(&prop->fmtid), prop->pid, out); + TRACE("%s, (%s,%lu), %p\n", wine_dbgstr_guid(guid), wine_dbgstr_guid(&prop->fmtid), prop->pid, out);
if(!get_alsa_name_by_guid(guid, name, sizeof(name), &flow)) {