PulseAudio Marge Bot pushed to branch master at PulseAudio / pulseaudio
Commits: 1c1d0c78 by Georg Chini at 2021-04-20T12:18:43+02:00 stream-restore: Fix use of uninitialized variable The variable card_name in sink_input_preferred_sink_changed_cb and source_output_preferred_source_changed_cb could be used uninitialized, which leads to invalid database entries. This patch fixes the problem. Part-of: <https://gitlab.freedesktop.org/pulseaudio/pulseaudio/-/merge_requests/543> - - - - - 1 changed file: - src/modules/module-stream-restore.c Changes: ===================================== src/modules/module-stream-restore.c ===================================== @@ -1594,7 +1594,7 @@ static void update_preferred_device(struct userdata *u, const char *name, const static pa_hook_result_t sink_input_preferred_sink_changed_cb(pa_core *c, pa_sink_input *sink_input, struct userdata *u) { char *name; pa_sink *sink; - const char *card_name; + const char *card_name = NULL; pa_assert(c); pa_assert(sink_input); @@ -1723,7 +1723,7 @@ static pa_hook_result_t source_output_fixate_hook_callback(pa_core *c, pa_source static pa_hook_result_t source_output_preferred_source_changed_cb(pa_core *c, pa_source_output *source_output, struct userdata *u) { char *name; pa_source *source; - const char *card_name; + const char *card_name = NULL; pa_assert(c); pa_assert(source_output); View it on GitLab: https://gitlab.freedesktop.org/pulseaudio/pulseaudio/-/commit/1c1d0c7827ba0e21038ad9215097cb7b2785ed3e -- View it on GitLab: https://gitlab.freedesktop.org/pulseaudio/pulseaudio/-/commit/1c1d0c7827ba0e21038ad9215097cb7b2785ed3e You're receiving this email because of your account on gitlab.freedesktop.org.
_______________________________________________ pulseaudio-commits mailing list [email protected] https://lists.freedesktop.org/mailman/listinfo/pulseaudio-commits
