summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorwm4 <wm4@nowhere>2013-11-27 21:12:09 +0100
committerwm4 <wm4@nowhere>2013-12-01 19:37:19 +0100
commitb9585e518bf1710af607a08b614922feffc7a0cd (patch)
tree41b08bdb21b6c7a594515d65287a37d4eefee7aa
parenta9858ab117315cd5f95594c34e03da5915bc8ad7 (diff)
downloadmpv-b9585e518bf1710af607a08b614922feffc7a0cd.tar.bz2
mpv-b9585e518bf1710af607a08b614922feffc7a0cd.tar.xz
af_lavi: actually free the filter graph on uninit
This was a memory leak. Also remove the AF_CONTROL_COMMAND_LINE code, which was inactive. (It's never called if the new option parser is used.)
-rw-r--r--audio/filter/af_lavfi.c6
1 files changed, 1 insertions, 5 deletions
diff --git a/audio/filter/af_lavfi.c b/audio/filter/af_lavfi.c
index 6b8a66d326..dfcde0c7e5 100644
--- a/audio/filter/af_lavfi.c
+++ b/audio/filter/af_lavfi.c
@@ -206,11 +206,6 @@ static int control(struct af_instance *af, int cmd, void *arg)
return mp_audio_config_equals(in, &orig_in) ? AF_OK : AF_FALSE;
}
- case AF_CONTROL_COMMAND_LINE: {
- talloc_free(p->cfg_graph);
- p->cfg_graph = talloc_strdup(p, (char *)arg);
- return AF_OK;
- }
}
return AF_UNKNOWN;
}
@@ -291,6 +286,7 @@ static struct mp_audio *play(struct af_instance *af, struct mp_audio *data)
static void uninit(struct af_instance *af)
{
+ destroy_graph(af);
}
static int af_open(struct af_instance *af)