diff options
Diffstat (limited to 'src/modules/module-alsa-sink.c')
-rw-r--r-- | src/modules/module-alsa-sink.c | 38 |
1 files changed, 19 insertions, 19 deletions
diff --git a/src/modules/module-alsa-sink.c b/src/modules/module-alsa-sink.c index 0cebd50f..6ff9a6e4 100644 --- a/src/modules/module-alsa-sink.c +++ b/src/modules/module-alsa-sink.c @@ -125,10 +125,10 @@ static int xrun_recovery(struct userdata *u) { int ret; assert(u); - pa_log_info(__FILE__": *** ALSA-XRUN (playback) ***"); + pa_log_info("*** ALSA-XRUN (playback) ***"); if ((ret = snd_pcm_prepare(u->pcm_handle)) < 0) { - pa_log(__FILE__": snd_pcm_prepare() failed: %s", snd_strerror(-ret)); + pa_log("snd_pcm_prepare() failed: %s", snd_strerror(-ret)); clear_up(u); pa_module_unload_request(u->module); @@ -169,7 +169,7 @@ static void do_write(struct userdata *u) { continue; } - pa_log(__FILE__": snd_pcm_writei() failed: %s", snd_strerror(-frames)); + pa_log("snd_pcm_writei() failed: %s", snd_strerror(-frames)); clear_up(u); pa_module_unload_request(u->module); @@ -233,7 +233,7 @@ static pa_usec_t sink_get_latency_cb(pa_sink *s) { assert(s && u && u->sink); if ((err = snd_pcm_delay(u->pcm_handle, &frames)) < 0) { - pa_log(__FILE__": failed to get delay: %s", snd_strerror(err)); + pa_log("failed to get delay: %s", snd_strerror(err)); s->get_latency = NULL; return 0; } @@ -275,7 +275,7 @@ static int sink_get_hw_volume_cb(pa_sink *s) { return 0; fail: - pa_log_error(__FILE__": Unable to read volume: %s", snd_strerror(err)); + pa_log_error("Unable to read volume: %s", snd_strerror(err)); s->get_hw_volume = NULL; s->set_hw_volume = NULL; return -1; @@ -309,7 +309,7 @@ static int sink_set_hw_volume_cb(pa_sink *s) { return 0; fail: - pa_log_error(__FILE__": Unable to set volume: %s", snd_strerror(err)); + pa_log_error("Unable to set volume: %s", snd_strerror(err)); s->get_hw_volume = NULL; s->set_hw_volume = NULL; return -1; @@ -323,7 +323,7 @@ static int sink_get_hw_mute_cb(pa_sink *s) { err = snd_mixer_selem_get_playback_switch(u->mixer_elem, 0, &sw); if (err) { - pa_log_error(__FILE__": Unable to get switch: %s", snd_strerror(err)); + pa_log_error("Unable to get switch: %s", snd_strerror(err)); s->get_hw_mute = NULL; s->set_hw_mute = NULL; return -1; @@ -342,7 +342,7 @@ static int sink_set_hw_mute_cb(pa_sink *s) { err = snd_mixer_selem_set_playback_switch_all(u->mixer_elem, !s->hw_muted); if (err) { - pa_log_error(__FILE__": Unable to set switch: %s", snd_strerror(err)); + pa_log_error("Unable to set switch: %s", snd_strerror(err)); s->get_hw_mute = NULL; s->set_hw_mute = NULL; return -1; @@ -369,13 +369,13 @@ int pa__init(pa_core *c, pa_module*m) { int namereg_fail; if (!(ma = pa_modargs_new(m->argument, valid_modargs))) { - pa_log(__FILE__": failed to parse module arguments"); + pa_log("failed to parse module arguments"); goto fail; } ss = c->default_sample_spec; if (pa_modargs_get_sample_spec_and_channel_map(ma, &ss, &map, PA_CHANNEL_MAP_ALSA) < 0) { - pa_log(__FILE__": failed to parse sample specification and channel map"); + pa_log("failed to parse sample specification and channel map"); goto fail; } @@ -386,7 +386,7 @@ int pa__init(pa_core *c, pa_module*m) { fragsize = pa_bytes_per_second(&ss)/128; if (pa_modargs_get_value_u32(ma, "fragments", &periods) < 0 || pa_modargs_get_value_u32(ma, "fragment_size", &fragsize) < 0) { - pa_log(__FILE__": failed to parse buffer metrics"); + pa_log("failed to parse buffer metrics"); goto fail; } period_size = fragsize/frame_size; @@ -397,18 +397,18 @@ int pa__init(pa_core *c, pa_module*m) { snd_config_update_free_global(); if ((err = snd_pcm_open(&u->pcm_handle, dev = pa_modargs_get_value(ma, "device", DEFAULT_DEVICE), SND_PCM_STREAM_PLAYBACK, SND_PCM_NONBLOCK)) < 0) { - pa_log(__FILE__": Error opening PCM device %s: %s", dev, snd_strerror(err)); + pa_log("Error opening PCM device %s: %s", dev, snd_strerror(err)); goto fail; } if ((err = snd_pcm_info_malloc(&pcm_info)) < 0 || (err = snd_pcm_info(u->pcm_handle, pcm_info)) < 0) { - pa_log(__FILE__": Error fetching PCM info: %s", snd_strerror(err)); + pa_log("Error fetching PCM info: %s", snd_strerror(err)); goto fail; } if ((err = pa_alsa_set_hw_params(u->pcm_handle, &ss, &periods, &period_size)) < 0) { - pa_log(__FILE__": Failed to set hardware parameters: %s", snd_strerror(err)); + pa_log("Failed to set hardware parameters: %s", snd_strerror(err)); goto fail; } @@ -417,7 +417,7 @@ int pa__init(pa_core *c, pa_module*m) { pa_channel_map_init_auto(&map, ss.channels, PA_CHANNEL_MAP_ALSA); if ((err = snd_mixer_open(&u->mixer_handle, 0)) < 0) { - pa_log(__FILE__": Error opening mixer: %s", snd_strerror(err)); + pa_log("Error opening mixer: %s", snd_strerror(err)); goto fail; } @@ -435,7 +435,7 @@ int pa__init(pa_core *c, pa_module*m) { } if (!(u->sink = pa_sink_new(c, __FILE__, name, namereg_fail, &ss, &map))) { - pa_log(__FILE__": Failed to create sink object"); + pa_log("Failed to create sink object"); goto fail; } @@ -471,7 +471,7 @@ int pa__init(pa_core *c, pa_module*m) { u->pcm_fdl = pa_alsa_fdlist_new(); assert(u->pcm_fdl); if (pa_alsa_fdlist_init_pcm(u->pcm_fdl, u->pcm_handle, c->mainloop, fdl_callback, u) < 0) { - pa_log(__FILE__": failed to initialise file descriptor monitoring"); + pa_log("failed to initialise file descriptor monitoring"); goto fail; } @@ -479,7 +479,7 @@ int pa__init(pa_core *c, pa_module*m) { u->mixer_fdl = pa_alsa_fdlist_new(); assert(u->mixer_fdl); if (pa_alsa_fdlist_init_mixer(u->mixer_fdl, u->mixer_handle, c->mainloop) < 0) { - pa_log(__FILE__": failed to initialise file descriptor monitoring"); + pa_log("failed to initialise file descriptor monitoring"); goto fail; } snd_mixer_elem_set_callback(u->mixer_elem, mixer_callback); @@ -490,7 +490,7 @@ int pa__init(pa_core *c, pa_module*m) { u->frame_size = frame_size; u->fragment_size = period_size * frame_size; - pa_log_info(__FILE__": using %u fragments of size %lu bytes.", periods, (long unsigned)u->fragment_size); + pa_log_info("using %u fragments of size %lu bytes.", periods, (long unsigned)u->fragment_size); u->silence.memblock = pa_memblock_new(c->mempool, u->silence.length = u->fragment_size); assert(u->silence.memblock); |