v4l2src: fix 'hang' with some cameras caused by bad timestamping if no framerate...
authorHans de Goede <jwrdegoede@fedoraproject.org>
Fri, 14 Aug 2009 11:44:06 +0000 (12:44 +0100)
committerTim-Philipp Müller <tim.muller@collabora.co.uk>
Fri, 14 Aug 2009 12:30:31 +0000 (13:30 +0100)
commit10d41286d5bf738a8a7f7537682958b085990e86
tree09ec5176b88f2b872883f87069c06201e99f9b6a
parenta3a61f89403cd39fd08f2f1d0e1475f55b0a48f4
v4l2src: fix 'hang' with some cameras caused by bad timestamping if no framerate is available

For cameras/drivers that don't support e.g. VIDIOC_G_PARM we'd end up without
a framerate and would try to divide by 0, causing run-time warnings and all
frames to be timestamped with 0, which makes sinks that sync against the clock
drop them, causing 'hangs' (observed with the pwc driver and a Logitech QuickCam
Pro 4000). So if we do not know the framerate, simply don't adjust the
timestamps. Fixes #591451.
sys/v4l2/gstv4l2src.c