# HG changeset patch # User reimar # Date 1239358421 0 # Node ID bae666342ba9a67cf51407a5e460192c96369f7e # Parent aa06c29db609ee0c9d0f5be13f85be79aa3be3a1 Make tvi_v4l2 print -1 as "Current input" if the ioctl to read it failed. Previously it printed (number of inputs + 1) which is needlessly confusing. diff -r aa06c29db609 -r bae666342ba9 stream/tvi_v4l2.c --- a/stream/tvi_v4l2.c Thu Apr 09 20:20:00 2009 +0000 +++ b/stream/tvi_v4l2.c Fri Apr 10 10:13:41 2009 +0000 @@ -1313,6 +1313,7 @@ } mp_msg(MSGT_TV, MSGL_INFO, " %d = %s;", i, input.name); } + i = -1; if (ioctl(priv->video_fd, VIDIOC_G_INPUT, &i) < 0) { mp_msg(MSGT_TV, MSGL_ERR, "%s: ioctl get input failed: %s\n", info.short_name, strerror(errno));