From fffd2133850b23a40ed828d28fb3e966812dc38e Mon Sep 17 00:00:00 2001 From: flo Date: Sat, 10 Sep 2011 10:35:10 +0000 Subject: add a patch which prevents firefox from using 100% cpu. FreeBSD sets POLLHUP in case a connect failed and the socket has never been connected. NSPR should also check for this. The patch has already been committed upstream. Bugzilla ID 684758 PR: ports/156889 Analyzed by: avg Patch by: avg Approved by: kwm --- devel/nspr/Makefile | 1 + devel/nspr/files/patch-bugzilla-684758 | 11 +++++++++++ 2 files changed, 12 insertions(+) create mode 100644 devel/nspr/files/patch-bugzilla-684758 diff --git a/devel/nspr/Makefile b/devel/nspr/Makefile index 4e04df590d56..5d26220a24d9 100644 --- a/devel/nspr/Makefile +++ b/devel/nspr/Makefile @@ -7,6 +7,7 @@ PORTNAME= nspr DISTVERSION= 4.8.8 +PORTREVISION= 1 CATEGORIES= devel MASTER_SITES= MOZILLA MASTER_SITE_SUBDIR= nspr/releases/v${PORTVERSION}/src diff --git a/devel/nspr/files/patch-bugzilla-684758 b/devel/nspr/files/patch-bugzilla-684758 new file mode 100644 index 000000000000..efdb0c102451 --- /dev/null +++ b/devel/nspr/files/patch-bugzilla-684758 @@ -0,0 +1,11 @@ +--- ../pr/src/pthreads/ptio.c 2011-09-02 12:14:24.000000000 +0200 ++++ ../pr/src/pthreads/ptio.c 2011-09-02 12:14:27.000000000 +0200 +@@ -1635,7 +1635,7 @@ + PR_SetError(PR_BAD_DESCRIPTOR_ERROR, 0); + return PR_FAILURE; + } +- if ((out_flags & (PR_POLL_WRITE | PR_POLL_EXCEPT | PR_POLL_ERR)) == 0) ++ if ((out_flags & (PR_POLL_WRITE | PR_POLL_EXCEPT | PR_POLL_ERR | PR_POLL_HUP)) == 0) + { + PR_ASSERT(out_flags == 0); + PR_SetError(PR_IN_PROGRESS_ERROR, 0); -- cgit