[totem-pl-parser] plparse: Fix small leak in totem_pl_parser_parse_internal()
- From: Christophe Fergeau <teuf src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [totem-pl-parser] plparse: Fix small leak in totem_pl_parser_parse_internal()
- Date: Tue, 19 Sep 2017 07:01:18 +0000 (UTC)
commit 9d744ac95e113d3b19b7ede813afec60f9d66e1a
Author: Christophe Fergeau <cfergeau redhat com>
Date: Mon Sep 18 11:11:31 2017 +0200
plparse: Fix small leak in totem_pl_parser_parse_internal()
Some local 'url' variable was not freed in one case before returning,
causing a small leak.
plparse/totem-pl-parser.c | 4 +++-
1 files changed, 3 insertions(+), 1 deletions(-)
---
diff --git a/plparse/totem-pl-parser.c b/plparse/totem-pl-parser.c
index bd46c03..dfee836 100644
--- a/plparse/totem-pl-parser.c
+++ b/plparse/totem-pl-parser.c
@@ -1828,8 +1828,10 @@ totem_pl_parser_parse_internal (TotemPlParser *parser,
url = g_file_get_uri (file);
if (url != NULL && totem_pl_parser_is_videosite (url, parser->priv->debug) != FALSE) {
ret = totem_pl_parser_add_videosite (parser, file, base_file, parse_data, NULL);
- if (ret == TOTEM_PL_PARSER_RESULT_SUCCESS)
+ if (ret == TOTEM_PL_PARSER_RESULT_SUCCESS) {
+ g_free (url);
return ret;
+ }
}
g_free (url);
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]