[grilo] core: Allow NULL param in grl_date_time_from_iso_8601()
- From: Juan A. Suarez Romero <jasuarez src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [grilo] core: Allow NULL param in grl_date_time_from_iso_8601()
- Date: Sat, 6 Jul 2013 10:37:26 +0000 (UTC)
commit 0897b071313d3ca5970c042718508a00922e432a
Author: Juan A. Suarez Romero <jasuarez igalia com>
Date: Sat Jul 6 10:36:16 2013 +0000
core: Allow NULL param in grl_date_time_from_iso_8601()
src/grl-util.c | 4 ++++
1 files changed, 4 insertions(+), 0 deletions(-)
---
diff --git a/src/grl-util.c b/src/grl-util.c
index 94935d2..1580b51 100644
--- a/src/grl-util.c
+++ b/src/grl-util.c
@@ -139,6 +139,10 @@ grl_date_time_from_iso8601 (const gchar *date)
gchar *date_time;
gint date_length;
+ if (!date) {
+ return NULL;
+ }
+
ret = g_time_val_from_iso8601 (date, &t);
/* second condition works around
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]