[gnome-commander] search: move assert from read_search_file() to content_matches()



commit ce026162a292d1f41b4f8241218f828935cf97b9
Author: Piotr Eljasiak <epiotr src gnome org>
Date:   Mon May 16 19:22:12 2011 +0200

    search: move assert from read_search_file() to content_matches()

 src/dialogs/gnome-cmd-search-dialog.cc |    6 +++---
 1 files changed, 3 insertions(+), 3 deletions(-)
---
diff --git a/src/dialogs/gnome-cmd-search-dialog.cc b/src/dialogs/gnome-cmd-search-dialog.cc
index 24b7425..2b62c80 100755
--- a/src/dialogs/gnome-cmd-search-dialog.cc
+++ b/src/dialogs/gnome-cmd-search-dialog.cc
@@ -151,9 +151,6 @@ inline void search_file_data_free (SearchFileData  *searchfile_data)
  */
 static SearchFileData *read_search_file (SearchData *data, SearchFileData *searchfile_data, GnomeCmdFile *f)
 {
-    g_return_val_if_fail (f != NULL, NULL);
-    g_return_val_if_fail (f->info != NULL, NULL);
-
     GnomeVFSResult  result;
 
     if (!searchfile_data)
@@ -228,6 +225,9 @@ static SearchFileData *read_search_file (SearchData *data, SearchFileData *searc
  */
 inline gboolean content_matches (GnomeCmdFile *f, SearchData *data)
 {
+    g_return_val_if_fail (f != NULL, FALSE);
+    g_return_val_if_fail (f->info != NULL, FALSE);
+
     gint ret = REG_NOMATCH;
 
     if (f->info->size > 0)



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