when display time, Change "T" to Space and not append time zone to maintain compatibility
authorhj kim <backto.kim@samsung.com>
Tue, 10 Nov 2020 06:50:21 +0000 (15:50 +0900)
committerbackto.kim <backto.kim@samsung.com>
Mon, 6 Dec 2021 06:49:13 +0000 (15:49 +0900)
NOTE: ISO 8601 defines date and time separated by "T".
Applications using this syntax may choose, for the sake of readability,
to specify a full-date and full-time separated by (say) a space character.

Change-Id: I30549ad4b59d8bbd354fd17723aaa58f33032817

libavutil/dict.c

index 9d3d96c..b9dbfb0 100644 (file)
@@ -262,9 +262,15 @@ int avpriv_dict_set_timestamp(AVDictionary **dict, const char *key, int64_t time
     ptm = gmtime_r(&seconds, &tmbuf);
     if (ptm) {
         char buf[32];
+#ifdef __TIZEN__
+        if (!strftime(buf, sizeof(buf), "%Y-%m-%d %H:%M:%S", ptm))
+            return AVERROR_EXTERNAL;
+#else
         if (!strftime(buf, sizeof(buf), "%Y-%m-%dT%H:%M:%S", ptm))
             return AVERROR_EXTERNAL;
         av_strlcatf(buf, sizeof(buf), ".%06dZ", (int)(timestamp % 1000000));
+#endif
+
         return av_dict_set(dict, key, buf, 0);
     } else {
         return AVERROR_EXTERNAL;