[tracker/gdbus-porting] libtracker-miner: Don't get len of status and don't check GVariant twice for NULL
- From: Martyn James Russell <mr src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [tracker/gdbus-porting] libtracker-miner: Don't get len of status and don't check GVariant twice for NULL
- Date: Tue, 4 Jan 2011 17:51:34 +0000 (UTC)
commit 603131b1eb1e62b0ab2a2f1cd92cf266cd29cc31
Author: Martyn Russell <martyn lanedo com>
Date: Tue Jan 4 10:43:52 2011 +0000
libtracker-miner: Don't get len of status and don't check GVariant twice for NULL
src/libtracker-miner/tracker-miner-manager.c | 10 ++++------
1 files changed, 4 insertions(+), 6 deletions(-)
---
diff --git a/src/libtracker-miner/tracker-miner-manager.c b/src/libtracker-miner/tracker-miner-manager.c
index 620371b..df801e2 100644
--- a/src/libtracker-miner/tracker-miner-manager.c
+++ b/src/libtracker-miner/tracker-miner-manager.c
@@ -891,13 +891,11 @@ tracker_miner_manager_get_status (TrackerMinerManager *manager,
return FALSE;
}
- if (v && status) {
- gsize len;
-
- *status = g_variant_dup_string (v, &len);
- }
-
if (v) {
+ if (status) {
+ *status = g_variant_dup_string (v, NULL);
+ }
+
g_variant_unref (v);
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]