r53990 - /trunk/libvideo-capture-v4l-perl/debian/patches/v4l2.patch
dmn at users.alioth.debian.org
dmn at users.alioth.debian.org
Tue Mar 9 20:09:43 UTC 2010
Author: dmn
Date: Tue Mar 9 20:07:12 2010
New Revision: 53990
URL: http://svn.debian.org/wsvn/pkg-perl/?sc=1&rev=53990
Log:
fix the ->{handle} member initialization
Modified:
trunk/libvideo-capture-v4l-perl/debian/patches/v4l2.patch
Modified: trunk/libvideo-capture-v4l-perl/debian/patches/v4l2.patch
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libvideo-capture-v4l-perl/debian/patches/v4l2.patch?rev=53990&op=diff
==============================================================================
--- trunk/libvideo-capture-v4l-perl/debian/patches/v4l2.patch (original)
+++ trunk/libvideo-capture-v4l-perl/debian/patches/v4l2.patch Tue Mar 9 20:07:12 2010
@@ -1,6 +1,14 @@
--- a/V4l/V4l.pm
+++ b/V4l/V4l.pm
-@@ -92,9 +92,8 @@ sub new(;$) {
+@@ -7,6 +7,7 @@ use vars qw($VERSION @ISA @EXPORT @EXPOR
+ require Exporter;
+ require DynaLoader;
+
++use IO::Handle;
+ use Fcntl;
+
+ $VERSION = '0.902';
+@@ -92,9 +93,8 @@ sub new(;$) {
my $device = shift || "/dev/video0";
my $self = bless { device => $device }, $class;
@@ -8,11 +16,11 @@
- sysopen $self->{handle},$device,O_RDWR or return;
- $self->{fd} = fileno ($self->{handle});
+ $self->{fd} = v4l_open($device,O_RDWR) or return;
-+ $self->{handle} = IO::Handle->new_from_fd( $self->{fd}, 'rw' );
++ $self->{handle} = IO::Handle->new_from_fd( $self->{fd}, 'w' );
$self->{capability} = _capabilities_new ($self->{fd});
$self->{picture} = _picture_new ($self->{fd});
-@@ -176,9 +175,8 @@ sub new(;$) {
+@@ -176,9 +176,8 @@ sub new(;$) {
my $device = shift || "/dev/vbi0";
my $self = bless { device => $device }, $class;
@@ -20,7 +28,7 @@
- sysopen $self->{handle},$device,O_RDWR or return;
- $self->{fd} = fileno ($self->{handle});
+ $self->{fd} = v4l_open($device,O_RDWR) or return;
-+ $self->{handle} = IO::Handle->new_from_fd( $self->{fd}, 'rw' );
++ $self->{handle} = IO::Handle->new_from_fd( $self->{fd}, 'w' );
$self
}
More information about the Pkg-perl-cvs-commits
mailing list