[grilo] [core] Added preconditions to grl_multiple_search



commit 91de9cbd997dd7f0c7aa3e7bc0daccccfaaade25
Author: Iago Toral Quiroga <itoral igalia com>
Date:   Tue Jun 1 16:49:55 2010 +0200

    [core] Added preconditions to grl_multiple_search

 src/grl-multiple.c |    4 ++++
 1 files changed, 4 insertions(+), 0 deletions(-)
---
diff --git a/src/grl-multiple.c b/src/grl-multiple.c
index 92a914e..9dabe44 100644
--- a/src/grl-multiple.c
+++ b/src/grl-multiple.c
@@ -98,6 +98,10 @@ grl_multiple_search (const gchar *text,
 
   g_debug ("grl_multiple_search");
 
+  g_return_val_if_fail (count > 0, 0);
+  g_return_val_if_fail (text != NULL, 0);
+  g_return_val_if_fail (callback != NULL, 0);
+
   registry = grl_plugin_registry_get_instance ();
   sources = grl_plugin_registry_get_sources_by_operations (registry,
 							   GRL_OP_SEARCH,



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