From bb3dfcbdf1569ee983dce9a9287ab8de262b2023 Mon Sep 17 00:00:00 2001
From: Benedikt Meurer <benny@xfce.org>
Date: Sat, 11 Feb 2006 00:57:28 +0000
Subject: [PATCH] 2006-02-10	Benedikt Meurer <benny@xfce.org>

	* thunar/thunar-list-model.c(thunar_list_model_cmp): Remove the safety
	  checks here, showing up too high in the profiler stats, and invalid
	  arguments to this function will be detected earlier (for debug
	  builds).




(Old svn revision: 19831)
---
 ChangeLog                  | 7 +++++++
 thunar/thunar-list-model.c | 6 +-----
 2 files changed, 8 insertions(+), 5 deletions(-)

diff --git a/ChangeLog b/ChangeLog
index 993e3946c..e90e88ff5 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,10 @@
+2006-02-10	Benedikt Meurer <benny@xfce.org>
+
+	* thunar/thunar-list-model.c(thunar_list_model_cmp): Remove the safety
+	  checks here, showing up too high in the profiler stats, and invalid
+	  arguments to this function will be detected earlier (for debug
+	  builds).
+
 2006-02-10	Benedikt Meurer <benny@xfce.org>
 
 	* docs/reference/thunar-vfs/: Update thunar-vfs API docs.
diff --git a/thunar/thunar-list-model.c b/thunar/thunar-list-model.c
index 549f4bc5b..fe11ea44f 100644
--- a/thunar/thunar-list-model.c
+++ b/thunar/thunar-list-model.c
@@ -975,10 +975,6 @@ thunar_list_model_cmp (ThunarListModel *store,
   gboolean isdir_a;
   gboolean isdir_b;
 
-  g_return_val_if_fail (THUNAR_IS_LIST_MODEL (store), -1);
-  g_return_val_if_fail (THUNAR_IS_FILE (a), -1);
-  g_return_val_if_fail (THUNAR_IS_FILE (b), -1);
-
   if (G_LIKELY (store->sort_folders_first))
     {
       isdir_a = thunar_file_is_directory (a);
@@ -990,7 +986,7 @@ thunar_list_model_cmp (ThunarListModel *store,
         return 1;
     }
 
-  return store->sort_func (a, b) * store->sort_sign;
+  return (*store->sort_func) (a, b) * store->sort_sign;
 }
 
 
-- 
GitLab