summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorAmitesh Singh <amitesh.sh@samsung.com>2017-11-14 10:30:55 +0900
committerAmitesh Singh <amitesh.sh@samsung.com>2017-11-14 10:45:17 +0900
commit20a0d8c26eac9ceaa594e384885cf2df7d347e17 (patch)
treee049c277087e64f74f103030431623a6e61b678a /src
parent9ba451c98addabe2f965312a4bea26f8a3f1da90 (diff)
test calendar: make format callback function better
Add comments too.
Diffstat (limited to 'src')
-rw-r--r--src/bin/elementary/test_calendar.c11
1 files changed, 6 insertions, 5 deletions
diff --git a/src/bin/elementary/test_calendar.c b/src/bin/elementary/test_calendar.c
index dbcf9463ad..d4c08d3752 100644
--- a/src/bin/elementary/test_calendar.c
+++ b/src/bin/elementary/test_calendar.c
@@ -409,11 +409,12 @@ _cal_format_cb(void *data EINA_UNUSED, Eina_Strbuf *str, const Eina_Value value)
409{ 409{
410 struct tm current_time; 410 struct tm current_time;
411 411
412 if (eina_value_type_get(&value) == EINA_VALUE_TYPE_TM) 412 //return if the value type is other than EINA_VALUE_TYPE_TM
413 { 413 if (eina_value_type_get(&value) != EINA_VALUE_TYPE_TM)
414 eina_value_get(&value, &current_time); 414 return;
415 eina_strbuf_append_strftime(str, "<< %b %y >>", &current_time); 415
416 } 416 eina_value_get(&value, &current_time);
417 eina_strbuf_append_strftime(str, "<< %b %y >>", &current_time);
417} 418}
418 419
419void 420void