BIND 10 trac2172, updated. 121e490ee2758601ee3443fcd4b53686f7283701 [2172] fix page_size regex

BIND 10 source code commits bind10-changes at lists.isc.org
Wed Aug 8 19:37:56 UTC 2012


The branch, trac2172 has been updated
       via  121e490ee2758601ee3443fcd4b53686f7283701 (commit)
      from  a47c2eae8dd926d05a7ba27f1cde67ac98006673 (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
commit 121e490ee2758601ee3443fcd4b53686f7283701
Author: Jelte Jansen <jelte at isc.org>
Date:   Wed Aug 8 12:37:07 2012 -0700

    [2172] fix page_size regex

-----------------------------------------------------------------------

Summary of changes:
 src/lib/python/isc/sysinfo/sysinfo.py |    4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

-----------------------------------------------------------------------
diff --git a/src/lib/python/isc/sysinfo/sysinfo.py b/src/lib/python/isc/sysinfo/sysinfo.py
index 5f9b97f..37446f9 100644
--- a/src/lib/python/isc/sysinfo/sysinfo.py
+++ b/src/lib/python/isc/sysinfo/sysinfo.py
@@ -446,7 +446,7 @@ class SysInfoOSX(SysInfoFreeBSDOSX):
             # store all values in a dict
             values = {}
             page_size = None
-            page_size_re = re.compile('page size of [0-9]+ bytes')
+            page_size_re = re.compile('.*page size of ([0-9]+) bytes')
             for line in lines:
                 page_size_m = page_size_re.match(line)
                 if page_size_m:
@@ -456,7 +456,7 @@ class SysInfoOSX(SysInfoFreeBSDOSX):
                     values[key] = value.strip()[:-1]
             # Only calculate memory if page size is known
             if page_size is not None:
-                self._mem_free = int(values['Pages free']) * page_size +
+                self._mem_free = int(values['Pages free']) * page_size +\
                                  int(values['Pages speculative']) * page_size
         except (subprocess.CalledProcessError, OSError):
             pass



More information about the bind10-changes mailing list