summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJens Georg <mail@jensge.org>2016-02-21 20:05:42 +0100
committerJens Georg <mail@jensge.org>2016-02-21 20:05:42 +0100
commit055d415004b3627fafb6c1e1cf94663e02ee93cb (patch)
tree583feb8ae0432cc7525e87aabeb78b171d2a772c
parent9ce6765e2168878a85c0c731c7dcaff5d2efcc93 (diff)
downloadrygel-055d415004b3627fafb6c1e1cf94663e02ee93cb.tar.gz
media-export: Don't leak XML doc in DVD parser
Signed-off-by: Jens Georg <mail@jensge.org>
-rw-r--r--src/plugins/media-export/rygel-media-export-dvd-parser.vala7
1 files changed, 6 insertions, 1 deletions
diff --git a/src/plugins/media-export/rygel-media-export-dvd-parser.vala b/src/plugins/media-export/rygel-media-export-dvd-parser.vala
index bfd4dbb0..ef97d944 100644
--- a/src/plugins/media-export/rygel-media-export-dvd-parser.vala
+++ b/src/plugins/media-export/rygel-media-export-dvd-parser.vala
@@ -66,7 +66,12 @@ internal class Rygel.DVDParser : GLib.Object {
throw new DVDParserError.NOT_AVAILABLE ("No DVD extractor found");
}
- yield this.get_information ();
+ var doc = this.get_information ();
+ if (doc == null) {
+ throw new DVDParserError.GENERAL ("Failed to read cache file");
+ }
+
+ delete doc;
}
public async Xml.Doc* get_information () throws Error {