Sign Up
Log In
Log In
or
Sign Up
Places
All Projects
Status Monitor
Collapse sidebar
SUSE:SLE-15-SP2:Update
pipewire.15840
0003-pulse-fix-pa_card_info-profiles2-array-to-...
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
File 0003-pulse-fix-pa_card_info-profiles2-array-to-be-NULL-terminated.patch of Package pipewire.15840
From 9c8279aa6e45398b745e99b889963a36bdbe7ebe Mon Sep 17 00:00:00 2001 From: George Kiagiadakis <george.kiagiadakis@collabora.com> Date: Wed, 17 Jun 2020 17:17:51 +0300 Subject: [PATCH] pulse: fix pa_card_info.profiles2 array to be NULL terminated profiles2 is meant to be NULL terminated, according to its documentation Fixes a crash in pavucontrol-qt --- pipewire-pulseaudio/src/introspect.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/pipewire-pulseaudio/src/introspect.c b/pipewire-pulseaudio/src/introspect.c index 526ddda8..5b2a7a1c 100644 --- a/pipewire-pulseaudio/src/introspect.c +++ b/pipewire-pulseaudio/src/introspect.c @@ -1239,13 +1239,13 @@ static void card_callback(struct card_data *d) { struct global *g = d->global; pa_card_info *i = &g->card_info.info; - int n_profiles, j; + int n_profiles, j = 0; struct param *p; n_profiles = g->card_info.n_profiles; i->profiles = alloca(sizeof(pa_card_profile_info) * n_profiles); - i->profiles2 = alloca(sizeof(pa_card_profile_info2 *) * n_profiles); + i->profiles2 = alloca(sizeof(pa_card_profile_info2 *) * n_profiles + 1); i->n_profiles = 0; pw_log_debug("context %p: info for %d", g->context, g->id); @@ -1282,6 +1282,7 @@ static void card_callback(struct card_data *d) i->active_profile2 = i->profiles2[j]; } } + i->profiles2[j] = NULL; d->cb(d->context, i, 0, d->userdata); }
Locations
Projects
Search
Status Monitor
Help
OpenBuildService.org
Documentation
API Documentation
Code of Conduct
Contact
Support
@OBShq
Terms
openSUSE Build Service is sponsored by
The Open Build Service is an
openSUSE project
.
Sign Up
Log In
Places
Places
All Projects
Status Monitor