From 11473a6a10aaa5e62050e7e52115e2f8f10de124 Mon Sep 17 00:00:00 2001 From: Anand Avati Date: Thu, 27 Mar 2014 08:03:52 -0700 Subject: common-utils: new dirent compatible time fmt Introduce a new time format without "/" and spaces, in order to be used in (virtual) filenames. Change-Id: I468be54f1ec7f45265add4c458e19d95567439f7 BUG: 1089216 Signed-off-by: Anand Avati Reviewed-on: http://review.gluster.org/7507 Tested-by: Gluster Build System Reviewed-by: Pranith Kumar Karampuri --- libglusterfs/src/common-utils.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'libglusterfs/src/common-utils.c') diff --git a/libglusterfs/src/common-utils.c b/libglusterfs/src/common-utils.c index bfc2fc6ade3..80d9d294053 100644 --- a/libglusterfs/src/common-utils.c +++ b/libglusterfs/src/common-utils.c @@ -2300,14 +2300,16 @@ static const char *__gf_timefmts[] = { "%F %T", "%Y/%m/%d-%T", "%b %d %T", - "%F %H%M%S" + "%F %H%M%S", + "%Y-%m-%d-%T", }; static const char *__gf_zerotimes[] = { "0000-00-00 00:00:00", "0000/00/00-00:00:00", "xxx 00 00:00:00", - "0000-00-00 000000" + "0000-00-00 000000", + "0000-00-00-00:00:00", }; void -- cgit