[evolution/evolution-3-12] Bug 739375 - Crash when sort folder with Due By column
- From: Milan Crha <mcrha src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [evolution/evolution-3-12] Bug 739375 - Crash when sort folder with Due By column
- Date: Thu, 30 Oct 2014 08:15:53 +0000 (UTC)
commit a6c26a3d17432e4217896796930d0ed46bb285fb
Author: Milan Crha <mcrha redhat com>
Date: Thu Oct 30 09:15:31 2014 +0100
Bug 739375 - Crash when sort folder with Due By column
e-util/e-table-extras.c | 6 +++++-
1 files changed, 5 insertions(+), 1 deletions(-)
---
diff --git a/e-util/e-table-extras.c b/e-util/e-table-extras.c
index 07f81ba..43fca94 100644
--- a/e-util/e-table-extras.c
+++ b/e-util/e-table-extras.c
@@ -113,7 +113,11 @@ e_int64ptr_compare (gconstpointer data1,
{
const gint64 *pa = data1, *pb = data2;
- return (*pa == *pb) ? 0 : (*pa < *pb) ? -1 : 1;
+ if (pa && pb)
+ return (*pa == *pb) ? 0 : (*pa < *pb) ? -1 : 1;
+
+ /* sort unset values before set */
+ return (!pa && !pb) ? 0 : (pa ? 1 : -1);
}
/* UTF-8 strncasecmp - not optimized */
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]