avoid the weird usage of assert() in the ALSA header files that gcc 4.2 wants to complain about

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@83974 65c4cc65-6c06-0410-ace0-fbb531ad65f3
1.4
Kevin P. Fleming 18 years ago
parent a8ec2e2356
commit e690ff69da

@ -367,7 +367,8 @@ static snd_pcm_t *alsa_card_init(char *dev, snd_pcm_stream_t stream)
} else
ast_log(LOG_DEBUG, "Opening device %s in %s mode\n", dev, (stream == SND_PCM_STREAM_CAPTURE) ? "read" : "write");
snd_pcm_hw_params_alloca(&hwparams);
hwparams = alloca(snd_pcm_hw_params_sizeof());
memset(hwparams, 0, snd_pcm_hw_params_sizeof());
snd_pcm_hw_params_any(handle, hwparams);
err = snd_pcm_hw_params_set_access(handle, hwparams, SND_PCM_ACCESS_RW_INTERLEAVED);
@ -416,7 +417,8 @@ static snd_pcm_t *alsa_card_init(char *dev, snd_pcm_stream_t stream)
if (err < 0)
ast_log(LOG_ERROR, "Couldn't set the new hw params: %s\n", snd_strerror(err));
snd_pcm_sw_params_alloca(&swparams);
swparams = alloca(snd_pcm_sw_params_sizeof());
memset(swparams, 0, snd_pcm_sw_params_sizeof());
snd_pcm_sw_params_current(handle, swparams);
#if 1

Loading…
Cancel
Save