[boinc] 01/02: Upload to unstable, fixing idle detection

Gianfranco Costamagna locutusofborg-guest at moszumanska.debian.org
Wed Jan 27 08:43:18 UTC 2016


This is an automated email from the git hooks/post-receive script.

locutusofborg-guest pushed a commit to branch master
in repository boinc.

commit 659f80985adc082e388a796ba9e2d39314128689
Author: Gianfranco Costamagna <costamagnagianfranco at yahoo.it>
Date:   Wed Jan 27 09:41:38 2016 +0100

    Upload to unstable, fixing idle detection
---
 debian/changelog                                   | 10 +++++
 .../85c8d0d85c73bbd3508d4e348226dcbcfec1402e.patch | 46 ++++++++++++++++++++++
 debian/patches/series                              |  1 +
 3 files changed, 57 insertions(+)

diff --git a/debian/changelog b/debian/changelog
index 97ecc69..4c9cf75 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,3 +1,13 @@
+boinc (7.6.22+dfsg-2) unstable; urgency=medium
+
+  * Upload to unstable
+  [ Preston Maness ]
+  * debian/patches/85c8d0d85c73bbd3508d4e348226dcbcfec1402e.patch:
+    fix resource leaks when opening display for idle detection.
+    Closes: #812835
+
+ -- Gianfranco Costamagna <locutusofborg at debian.org>  Wed, 27 Jan 2016 09:40:33 +0100
+
 boinc (7.6.22+dfsg-1exp3) experimental; urgency=medium
 
   * Drop 35x11-common_xhost-local, it is just an example
diff --git a/debian/patches/85c8d0d85c73bbd3508d4e348226dcbcfec1402e.patch b/debian/patches/85c8d0d85c73bbd3508d4e348226dcbcfec1402e.patch
new file mode 100644
index 0000000..de1d7e3
--- /dev/null
+++ b/debian/patches/85c8d0d85c73bbd3508d4e348226dcbcfec1402e.patch
@@ -0,0 +1,46 @@
+## Description: add some description
+## Origin/Author: add some origin or author
+## Bug: bug URL
+From 85c8d0d85c73bbd3508d4e348226dcbcfec1402e Mon Sep 17 00:00:00 2001
+From: Preston Maness <aggroskater at gmail.com>
+Date: Tue, 26 Jan 2016 23:24:36 -0600
+Subject: [PATCH] XSS Idle Detection Bugfix (XCloseDisplay)
+
+Apologies. My initial code didn't close the connections to the X
+displays after opening them. I had thought that falling out of scope
+would close the connection automatically. However, thanks to a bug
+report by Dan Merillat that I was able to replicate, I now know better:
+
+https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=812835
+
+This simple adjustment closes the connection to the display (if a
+connection succeeded in the first place; if XOpenDisplay() failed, it
+returns NULL and there is no connection). Testing on my end shows that
+this resolves the issue of the boinc client piling up new connections to
+X servers.
+---
+ client/hostinfo_unix.cpp | 4 ++++
+ 1 file changed, 4 insertions(+)
+
+diff --git a/client/hostinfo_unix.cpp b/client/hostinfo_unix.cpp
+index a1fc652..297831d 100644
+--- a/client/hostinfo_unix.cpp
++++ b/client/hostinfo_unix.cpp
+@@ -2090,6 +2090,7 @@ bool xss_idle(long idle_threshold) {
+ 	  "[idle_detection] XScreenSaver extension not available for DISPLAY '%s'.",
+ 	  it->c_str());
+       }
++      XCloseDisplay(disp);
+       continue;
+     }
+ 
+@@ -2098,6 +2099,9 @@ bool xss_idle(long idle_threshold) {
+     XScreenSaverQueryInfo(disp, DefaultRootWindow(disp), xssInfo);
+     idle_time = xssInfo->idle;
+ 
++    // Close the connection to the XServer
++    XCloseDisplay(disp);
++
+     // convert from milliseconds to seconds
+     idle_time = idle_time / 1000;
+ 
diff --git a/debian/patches/series b/debian/patches/series
index 6aa1b22..4d1e05a 100644
--- a/debian/patches/series
+++ b/debian/patches/series
@@ -33,3 +33,4 @@ fix-underlinking.patch
 882d0cdd43d39bec7328be79c9da73a04c597ec7.patch
 69abe830e6069ec2139783392e8d3a73fb7e6baf.patch
 fc4446f6027cc0d0e75e634f572b50b88588b57d.patch
+85c8d0d85c73bbd3508d4e348226dcbcfec1402e.patch

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-boinc/boinc.git



More information about the pkg-boinc-commits mailing list