Date: Sat, 21 Jan 2017 04:40:06 +0000 (UTC) From: Jan Beich <jbeich@FreeBSD.org> To: ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org Subject: svn commit: r432013 - in head/devel/ptlib: . files Message-ID: <201701210440.v0L4e6EX024616@repo.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: jbeich Date: Sat Jan 21 04:40:06 2017 New Revision: 432013 URL: https://svnweb.freebsd.org/changeset/ports/432013 Log: devel/ptlib: properly detect mmap(2) failure PR: 216019 MFH: 2017Q1 Added: head/devel/ptlib/files/patch-plugins_vidinput__bsd_vidinput__bsd.cxx (contents, props changed) head/devel/ptlib/files/patch-plugins_vidinput__v4l_vidinput__v4l.cxx (contents, props changed) Modified: head/devel/ptlib/Makefile (contents, props changed) Modified: head/devel/ptlib/Makefile ============================================================================== --- head/devel/ptlib/Makefile Sat Jan 21 04:39:52 2017 (r432012) +++ head/devel/ptlib/Makefile Sat Jan 21 04:40:06 2017 (r432013) @@ -3,6 +3,7 @@ PORTNAME= ptlib PORTVERSION= 2.10.11 +PORTREVISION= 1 CATEGORIES= devel MASTER_SITES= GNOME Added: head/devel/ptlib/files/patch-plugins_vidinput__bsd_vidinput__bsd.cxx ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/devel/ptlib/files/patch-plugins_vidinput__bsd_vidinput__bsd.cxx Sat Jan 21 04:40:06 2017 (r432013) @@ -0,0 +1,11 @@ +--- plugins/vidinput_bsd/vidinput_bsd.cxx.orig 2013-08-14 23:20:28 UTC ++++ plugins/vidinput_bsd/vidinput_bsd.cxx +@@ -308,7 +308,7 @@ PBoolean PVideoInputDevice_BSDCAPTURE::G + + mmap_size = frameBytes; + videoBuffer = (BYTE *)::mmap(0, mmap_size, PROT_READ, 0, videoFd, 0); +- if (videoBuffer < 0) { ++ if (videoBuffer == MAP_FAILED) { + return PFalse; + } else { + canMap = 1; Added: head/devel/ptlib/files/patch-plugins_vidinput__v4l_vidinput__v4l.cxx ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/devel/ptlib/files/patch-plugins_vidinput__v4l_vidinput__v4l.cxx Sat Jan 21 04:40:06 2017 (r432013) @@ -0,0 +1,11 @@ +--- plugins/vidinput_v4l/vidinput_v4l.cxx.orig 2013-08-14 23:20:28 UTC ++++ plugins/vidinput_v4l/vidinput_v4l.cxx +@@ -978,7 +978,7 @@ PBoolean PVideoInputDevice_V4L::GetFrame + } else { + videoBuffer = (BYTE *)::mmap(0, frame.size, PROT_READ|PROT_WRITE, MAP_SHARED, videoFd, 0); + +- if (videoBuffer < 0) { ++ if (videoBuffer == MAP_FAILED) { + canMap = 0; + PTRACE(3, "VideoGrabber " << deviceName << " cannot do memory mapping - ::mmap failed."); + //This video device cannot do memory mapping.
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201701210440.v0L4e6EX024616>