mirror of
https://gitlab.freedesktop.org/pulseaudio/pulseaudio.git
synced 2025-12-17 08:56:42 -05:00
core: fix potential memory leak
This commit is contained in:
parent
c3d83b17ea
commit
49fd49f21f
1 changed files with 3 additions and 1 deletions
|
|
@ -1982,8 +1982,10 @@ static char *get_path(const char *fn, pa_bool_t prependmid, pa_bool_t rt) {
|
||||||
if (fn) {
|
if (fn) {
|
||||||
char *r;
|
char *r;
|
||||||
|
|
||||||
if (pa_is_path_absolute(fn))
|
if (pa_is_path_absolute(fn)) {
|
||||||
|
pa_xfree(rtp);
|
||||||
return pa_xstrdup(fn);
|
return pa_xstrdup(fn);
|
||||||
|
}
|
||||||
|
|
||||||
if (!rtp)
|
if (!rtp)
|
||||||
return NULL;
|
return NULL;
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue