Your message dated Fri, 3 Jul 2015 15:37:14 -0700
with message-id 
<CACZd_tAFUfmCAn6j2zq+QVdv=ktek0kx71li4uxjr8bbwdi...@mail.gmail.com>
and subject line Re: libgloox7: Too short receive timeout causes gloox to busy 
wait
has caused the Debian Bug report #562696,
regarding libgloox7: Too short receive timeout causes gloox to busy wait
to be marked as done.

This means that you claim that the problem has been dealt with.
If this is not the case it is now your responsibility to reopen the
Bug report if necessary, and/or fix the problem forthwith.

(NB: If you are a system administrator and have no idea what this
message is talking about, this may indicate a serious mail system
misconfiguration somewhere. Please contact [email protected]
immediately.)


-- 
562696: http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=562696
Debian Bug Tracking System
Contact [email protected] with problems
--- Begin Message ---
Subject: libgloox7: Too short receive timeout causes gloox to busy wait
Package: libgloox7
Version: 0.9.9.5-1.2
Severity: normal
Tags: patch

In ConnectionTCPBase::receive(), there is a line:

while( !m_cancel && ( err = recv( 10 ) ) == ConnNoError )

This is a timeout of 10 microseconds, which causes recv() to immediately timeout and in fact busy-wait, uselessly eating significant amount of CPU time. More sane timeout value should be used.

Bug can be solved with following small patch or by updating the package to version in upstream SVN branch 1.0, where this is already fixed.


--- gloox-0.9.9.5/src/connectiontcpbase.cpp     2008-04-26 13:47:24.000000000 
+0200
+++ connectiontcpbase.cpp       2009-12-27 02:40:39.940853288 +0100
@@ -107,7 +107,7 @@
       return ConnNotConnected;

     ConnectionError err = ConnNoError;
-    while( !m_cancel && ( err = recv( 10 ) ) == ConnNoError )
+    while( !m_cancel && ( err = recv( 1000000 ) ) == ConnNoError )
       ;
     return err == ConnNoError ? ConnNotConnected : err;
   }



-- System Information:
Debian Release: squeeze/sid
  APT prefers testing
  APT policy: (500, 'testing'), (500, 'stable')
Architecture: i386 (i686)

Kernel: Linux 2.6.30-2-686 (SMP w/1 CPU core)
Locale: LANG=en_US.UTF-8, LC_CTYPE=en_US.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/bash

Versions of packages libgloox7 depends on:
ii  libc6                  2.10.2-2          GNU C Library: Shared libraries
ii  libgcc1                1:4.4.2-3         GCC support library
ii  libgnutls26            2.8.5-2           the GNU TLS library - runtime libr
ii  libidn11               1.15-2            GNU Libidn library, implementation
ii  libstdc++6             4.4.2-3           The GNU Standard C++ Library v3
ii  zlib1g                 1:1.2.3.3.dfsg-15 compression library - runtime

libgloox7 recommends no packages.

libgloox7 suggests no packages.

-- no debconf information



--- End Message ---
--- Begin Message ---
Version: 1.0.9-1

Fixed a long time ago; looks like this bug just got lost during an
earlier transition.

Regards,
Vincent

--- End Message ---

Reply via email to