GNOME Bugzilla – Bug 707975
qtdemux: Can't handle datetimes before 1970 yet
Last modified: 2013-09-30 08:25:46 UTC
trying to play this file http://ftp.nluug.nl/ftp/graphics/blender/apricot/trailer/sintel_trailer-1080p.mp4 leads to the following warning from qtdemux 0:00:00.127056311 2783 0x191e7b0 WARN qtdemux qtdemux.c:8854:qtdemux_parse_tree:<qtdemux0> Can't handle datetimes before 1970 yet, please file a bug at http://bugzilla.gnome.org I am using 0.10 branch but I am not sure it's reproducible on 1.0 or not but a bug is being filed per the warning ;)
Still happens with latest git master: 0:00:00.129251237 4368 0x7f93e00f7770 WARN qtdemux qtdemux.c:9810:qtdemux_parse_tree:<qtdemux0> Can't handle datetimes before 1970 yet, please file a bug at http://bugzilla.gnome.org
Created attachment 255034 [details] [review] qtdemux: add code to parse creation time earlier than 1970 Use g_date_time seconds manipulation to allow to cover the quicktime spec for creation_time. It uses seconds since 1904. Both paths could be done using the generic approach of seconds since 1904 with GDateTime handling, but the first path using seconds from 1970 should be more commonly found and avoids a few objects creation and ref/unref, so keep it there for performance. Additionally, the code for handling seconds since 1970 changed from > to >= because having 0 seconds since 1970 is also a valid case for that path to handle. ---- This particular sample has a creation_time of 1970-01-01 00:00:00, so it could be handled directly by simply changing the > for a >= in the creation_time sanity check. However, as we visit this code, let's fix it for once and add 'seconds since 1904' handling.
commit dc02d91c14847e48b6e830ff58f2dd27ecae336d Author: Thiago Santos <thiago.sousa.santos@collabora.com> Date: Mon Sep 16 11:20:51 2013 -0300 qtdemux: add code to parse creation time earlier than 1970 Use g_date_time seconds manipulation to allow to cover the quicktime spec for creation_time. It uses seconds since 1904. Both paths could be done using the generic approach of seconds since 1904 with GDateTime handling, but the first path using seconds from 1970 should be more commonly found and avoids a few objects creation and ref/unref, so keep it there for performance. Additionally, the code for handling seconds since 1970 changed from > to >= because having 0 seconds since 1970 is also a valid case for that path to handle. https://bugzilla.gnome.org/show_bug.cgi?id=707975