[tracker/index-optical-discs] libtracker-miner: Fixed possible memory leak on content_type
- From: Philip Van Hoof <pvanhoof src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [tracker/index-optical-discs] libtracker-miner: Fixed possible memory leak on content_type
- Date: Thu, 4 Mar 2010 16:58:29 +0000 (UTC)
commit fa0b0be0ac4a33f153f4709d9eec7b9252b81d99
Author: Philip Van Hoof <philip codeminded be>
Date: Thu Mar 4 17:57:50 2010 +0100
libtracker-miner: Fixed possible memory leak on content_type
src/libtracker-miner/tracker-storage.c | 3 +++
1 files changed, 3 insertions(+), 0 deletions(-)
---
diff --git a/src/libtracker-miner/tracker-storage.c b/src/libtracker-miner/tracker-storage.c
index 727bc6c..2de4f5c 100644
--- a/src/libtracker-miner/tracker-storage.c
+++ b/src/libtracker-miner/tracker-storage.c
@@ -371,6 +371,7 @@ mount_guess_content_type (GFile *mount_root,
!g_strcmp0 (guess_type[i], "x-content/blank-hddvd")) {
/* Blank */
content_type = g_strdup (guess_type[i]);
+ break;
} else if (!g_strcmp0 (guess_type[i], "x-content/software") ||
!g_strcmp0 (guess_type[i], "x-content/unix-software") ||
!g_strcmp0 (guess_type[i], "x-content/win32-software")) {
@@ -379,8 +380,10 @@ mount_guess_content_type (GFile *mount_root,
* none-optical mount points?
*/
content_type = g_strdup (guess_type[i]);
+ break;
} else if (!content_type) {
content_type = g_strdup (guess_type[i]);
+ break;
}
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]