From 392b8f0d1a5aa7d9bf894053917bc389ca3026f4 Mon Sep 17 00:00:00 2001 From: Michael Gernoth Date: Tue, 7 Nov 2006 16:48:48 +0000 Subject: [PATCH] sometimes libao corrupts memory, so don't call ao_initialize and ao_shutdown when it's not really needed git-svn-id: svn://svn.code.sf.net/p/rdesktop/code/trunk/rdesktop@1333 423420c4-83ab-492f-b58f-81f9feb106b5 --- rdpsnd_libao.c | 20 +------------------- 1 file changed, 1 insertion(+), 19 deletions(-) diff --git a/rdpsnd_libao.c b/rdpsnd_libao.c index 1c15a37..8832915 100644 --- a/rdpsnd_libao.c +++ b/rdpsnd_libao.c @@ -179,8 +179,6 @@ struct audio_driver * libao_register(char *options) { static struct audio_driver libao_driver; - struct ao_info *libao_info; - static char description[101]; libao_driver.wave_out_open = libao_open; libao_driver.wave_out_close = libao_close; @@ -189,27 +187,11 @@ libao_register(char *options) libao_driver.wave_out_volume = rdpsnd_dsp_softvol_set; libao_driver.wave_out_play = libao_play; libao_driver.name = xstrdup("libao"); - libao_driver.description = description; + libao_driver.description = xstrdup("libao output driver, default device: system dependent"); libao_driver.need_byteswap_on_be = 1; libao_driver.need_resampling = 1; libao_driver.next = NULL; - ao_initialize(); - - libao_info = ao_driver_info(ao_default_driver_id()); - - if (libao_info) - { - snprintf(description, 100, "libao output driver, default device: %s", - libao_info->short_name); - } - else - { - snprintf(description, 100, "libao output driver, default device: none"); - } - - ao_shutdown(); - if (options) { libao_device = xstrdup(options);