MCPcopy Create free account
hub / github.com/HandBrake/HandBrake / get_creation_date

Function get_creation_date

gtk/src/callbacks.c:762–784  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

760}
761
762G_GNUC_STRFTIME(1) static char*
763get_creation_date(const char *pattern, const char *metaValue, const char *file)
764{
765 char date[11] = "";
766 if (metaValue != NULL && strlen(metaValue) > 1)
767 {
768 struct tm tm;
769 if (parse_datestring(metaValue, &tm))
770 {
771 strftime(date, 11, pattern, &tm);
772 }
773 }
774 else
775 {
776 GStatBuf stbuf;
777 if (g_stat(file, &stbuf) == 0){
778 struct tm *tm;
779 tm = localtime(&(stbuf.st_mtime));
780 strftime(date, 11, pattern, tm);
781 }
782 }
783 return strdup(date);
784}
785
786static void
787make_unique_dest(const gchar *dest_dir, GString *str, const gchar * extension)

Callers 1

set_destination_settingsFunction · 0.85

Calls 1

parse_datestringFunction · 0.85

Tested by

no test coverage detected