Package: kdetv Version: 0.8.9-1 Severity: important Tags: squeeze patch
Kdetv has not found any video device at my system. It assumes that if the directory /dev/v4l exists the video device is also in this directory. $ ll /dev/video0 crw-rw----+ 1 root video 81, 0 22. Mai 01:40 /dev/video0 $ ll /dev/v4l/ insgesamt 0 drwxr-xr-x 2 root root 80 21. Mai 19:52 by-path $ ll -d /dev/v4l/ drwxr-xr-x 3 root root 60 21. Mai 19:52 /dev/v4l/ The attached patch does only check all devices: /dev/video /dev/video[0-9] /dev/v4l/video[0-9] -- System Information: Debian Release: squeeze/sid APT prefers testing APT policy: (200, 'testing') Architecture: i386 (i686) Kernel: Linux 2.6.32-3-686 (SMP w/2 CPU cores) Locale: LANG=de_DE.UTF-8, LC_CTYPE=de_DE.UTF-8 (charmap=UTF-8) Shell: /bin/sh linked to /bin/bash Versions of packages kdetv depends on: ii kdelibs4c2a 4:3.5.10.dfsg.1-3 core libraries and binaries for al ii libasound2 1.0.22-2 shared library for ALSA applicatio ii libc6 2.10.2-6 Embedded GNU C Library: Shared lib ii libgcc1 1:4.4.4-1 GCC support library ii libice6 2:1.0.6-1 X11 Inter-Client Exchange library ii libpng12-0 1.2.43-1 PNG library - runtime ii libqt3-mt 3:3.3.8b-6 Qt GUI Library (Threaded runtime v ii libsm6 2:1.1.1-1 X11 Session Management library ii libstdc++6 4.4.4-1 The GNU Standard C++ Library v3 ii libx11-6 2:1.3.3-3 X11 client-side library ii libxext6 2:1.1.1-3 X11 miscellaneous extension librar ii libxinerama1 2:1.1-3 X11 Xinerama extension library ii libxrandr2 2:1.3.0-3 X11 RandR extension library ii libxrender1 1:0.9.5-2 X Rendering Extension client libra ii libxv1 2:1.0.5-1 X11 Video extension library ii libxvmc1 2:1.0.5-1 X11 Video extension library ii libxxf86dga1 2:1.1.1-2 X11 Direct Graphics Access extensi ii libxxf86vm1 1:1.1.0-2 X11 XFree86 video mode extension l ii libzvbi0 0.2.33-1 Vertical Blanking Interval decoder ii zlib1g 1:1.2.3.4.dfsg-3 compression library - runtime Versions of packages kdetv recommends: ii v4l-conf 3.95.dfsg.1-8.1 tool to configure video4linux driv Versions of packages kdetv suggests: ii kdelirc 4:4.4.3-1 infrared remote control for KDE 4 -- no debconf information --- kdetv-0.8.9/kdetv/plugins/video/v4l2/kdetv_v4l2.cpp 2006-07-09 20:30:53.000000000 +0200 +++ ../kdetv-0.8.9/kdetv/plugins/video/v4l2/kdetv_v4l2.cpp 2010-05-22 01:39:49.000000000 +0200 @@ -479,50 +479,32 @@ int KdetvV4L2::probeDevices() { - QString dev; - struct stat sb; - - // don't probe multiple times, it's unnecessary and might yield incorrect // results if plugin is currently using the device if (_probed) return 0; - int rc = stat("/dev/v4l", &sb); - if (!rc && S_ISDIR(sb.st_mode) && !access("/dev/v4l", R_OK|X_OK)) { - // DEVFS - dev = "/dev/v4l/video%1"; - } else { - // Normal V4L2 case - dev = "/dev/video%1"; - } - _devices.clear(); _sources.clear(); _tuners.clear(); _encodings.clear(); _devNames.clear(); + QStringList devs; + devs << "/dev/video"; + for (int i = 0; i <= 9; i++) { + devs << QString("/dev/v4l/video%1").arg(i); + devs << QString("/dev/video%1").arg(i); + } + QString mainVideoDev = QString::null; // FIXME: when we test for devices, we must make sure that we can // actually use them too. This fails for cases where something else // is using the device currently. - if (!access("/dev/video", R_OK|W_OK)) { - V4L2Dev *vd = V4L2Dev::getDevice("/dev/video"); - if (vd) { - QString name = "Video4Linux2: " + vd->name(); - _tuners[name] = vd->isTuner(); - _sources[name] = vd->sources(); - _encodings[name] = vd->encodings(); - _devices.append(name); - _devNames[name] = "/dev/video"; - mainVideoDev = QDir("/dev/video").canonicalPath(); - delete vd; - } - } - for (int i = 0; i <= 9; i++) { - QString dn = dev.arg(i); - if (dn != mainVideoDev && !access(dn.local8Bit(), R_OK|W_OK)) { + for (QStringList::const_iterator i = devs.begin(); i != devs.end(); i++) { + QString dn = *i; + qDebug("KdetvV4L2::probeDevices: probing %s", dn.ascii()); + if (!access(dn.local8Bit(), R_OK|W_OK)) { V4L2Dev *vd = V4L2Dev::getDevice(dn); if (vd) { QString name = i18n("Video4Linux2: ") + vd->name(); @@ -531,6 +513,10 @@ _encodings[name] = vd->encodings(); _devices.append(name); _devNames[name] = dn; + if (dn == "/dev/video") { + mainVideoDev = QDir(dn).canonicalPath(); + } + qDebug("KdetvV4L2::probeDevices: found %s", dn.ascii()); delete vd; } } -- To UNSUBSCRIBE, email to debian-bugs-dist-requ...@lists.debian.org with a subject of "unsubscribe". Trouble? Contact listmas...@lists.debian.org