[evolution-data-server] [Camel] Consider NULL and empty arrays/sets equal
- From: Milan Crha <mcrha src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [evolution-data-server] [Camel] Consider NULL and empty arrays/sets equal
- Date: Tue, 22 Nov 2016 11:20:12 +0000 (UTC)
commit be7946461b96fd6213d9059b2c38eb826bd3eedd
Author: Milan Crha <mcrha redhat com>
Date: Tue Nov 22 12:19:59 2016 +0100
[Camel] Consider NULL and empty arrays/sets equal
src/camel/camel-name-value-array.c | 2 +-
src/camel/camel-named-flags.c | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
---
diff --git a/src/camel/camel-name-value-array.c b/src/camel/camel-name-value-array.c
index 0a90e02..b25f593 100644
--- a/src/camel/camel-name-value-array.c
+++ b/src/camel/camel-name-value-array.c
@@ -615,7 +615,7 @@ camel_name_value_array_equal (const CamelNameValueArray *array_a,
return TRUE;
if (!array_a || !array_b)
- return FALSE;
+ return camel_name_value_array_get_length (array_a) == camel_name_value_array_get_length
(array_b);
len = camel_name_value_array_get_length (array_a);
if (len != camel_name_value_array_get_length (array_b))
diff --git a/src/camel/camel-named-flags.c b/src/camel/camel-named-flags.c
index 04d9d30..d920f04 100644
--- a/src/camel/camel-named-flags.c
+++ b/src/camel/camel-named-flags.c
@@ -304,7 +304,7 @@ camel_named_flags_equal (const CamelNamedFlags *named_flags_a,
return TRUE;
if (!named_flags_a || !named_flags_b)
- return FALSE;
+ return camel_named_flags_get_length (named_flags_a) == camel_named_flags_get_length
(named_flags_b);
len = camel_named_flags_get_length (named_flags_a);
if (len != camel_named_flags_get_length (named_flags_b))
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]