summaryrefslogtreecommitdiffstats
path: root/Alc
diff options
context:
space:
mode:
authorChris Robinson <[email protected]>2007-12-06 22:49:23 -0800
committerChris Robinson <[email protected]>2007-12-06 22:49:23 -0800
commit18f05cc1d129c572c05e1c7633f43f9125a6cd0b (patch)
treee1a7e34d40f5b257e91bb82eba11d098eb486151 /Alc
parentd608df5b22f74af0c73d69bf6049bc0d729d8c5a (diff)
Prevent some ICC warnings
Diffstat (limited to 'Alc')
-rw-r--r--Alc/ALu.c4
-rw-r--r--Alc/alsa.c8
2 files changed, 8 insertions, 4 deletions
diff --git a/Alc/ALu.c b/Alc/ALu.c
index cee00dd0..0821d6b4 100644
--- a/Alc/ALu.c
+++ b/Alc/ALu.c
@@ -407,8 +407,8 @@ ALvoid aluMixData(ALCcontext *ALContext,ALvoid *buffer,ALsizei size,ALenum forma
if(buffer)
{
//Figure output format variables
- BlockAlign = aluChannelsFromFormat(format) *
- aluBytesFromFormat(format);
+ BlockAlign = aluChannelsFromFormat(format);
+ BlockAlign *= aluBytesFromFormat(format);
size /= BlockAlign;
while(size > 0)
diff --git a/Alc/alsa.c b/Alc/alsa.c
index 98dd1531..2072ead0 100644
--- a/Alc/alsa.c
+++ b/Alc/alsa.c
@@ -751,6 +751,8 @@ LOAD_FUNC(snd_card_next);
dev = -1;
while (idx < MAX_ALL_DEVICES) {
+ const char *cname, *dname;
+
if (psnd_ctl_pcm_next_device(handle, &dev)<0)
AL_PRINT("snd_ctl_pcm_next_device failed\n");
if (dev < 0)
@@ -763,9 +765,11 @@ LOAD_FUNC(snd_card_next);
AL_PRINT("control digital audio info (%i): %s\n", card, psnd_strerror(err));
continue;
}
+
+ cname = psnd_ctl_card_info_get_name(info);
+ dname = psnd_pcm_info_get_name(pcminfo);
snprintf(name, sizeof(name), "ALSA Software on %s [%s]",
- psnd_ctl_card_info_get_name(info),
- psnd_pcm_info_get_name(pcminfo));
+ cname, dname);
allDevNameMap[idx].name = AppendAllDeviceList(name);
allDevNameMap[idx].card = card;
allDevNameMap[idx].dev = dev;