[tracker] libtracker-miner: fix error propagation in tracker_miner_manager_new_full



commit 6f0f046f8906c8aae7a93649ba065e12eb84a863
Author: Stefano Facchini <stefano facchini gmail com>
Date:   Tue Aug 23 14:58:08 2011 +0200

    libtracker-miner: fix error propagation in tracker_miner_manager_new_full
    
    Propagate inner_error and remove the warning message, letting the caller
    handle the error
    
    Fixes GB#657161

 src/libtracker-miner/tracker-miner-manager.c |    7 ++-----
 1 files changed, 2 insertions(+), 5 deletions(-)
---
diff --git a/src/libtracker-miner/tracker-miner-manager.c b/src/libtracker-miner/tracker-miner-manager.c
index 4adbf57..e84e606 100644
--- a/src/libtracker-miner/tracker-miner-manager.c
+++ b/src/libtracker-miner/tracker-miner-manager.c
@@ -604,11 +604,8 @@ tracker_miner_manager_new_full (gboolean   auto_start,
 	                          &inner_error,
 	                          "auto-start", auto_start,
 	                          NULL);
-	if (!manager) {
-		g_critical ("Couldn't create new TrackerMinerManager: '%s'",
-		            inner_error ? inner_error->message : "unknown error");
-		g_clear_error (&inner_error);
-	}
+	if (inner_error)
+		g_propagate_error (error, inner_error);
 
 	return manager;
 }



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]