Issue #13390: New function :func:sys.getallocatedblocks() returns the number of memory blocks currently allocated.

Also, the ``-R`` option to regrtest uses this function to guard against memory allocation leaks.
This commit is contained in:
Antoine Pitrou 2012-12-09 14:28:26 +01:00
parent b4b8f234d4
commit f9d0b1256f
9 changed files with 123 additions and 22 deletions

View file

@ -1772,7 +1772,7 @@ def strip_python_stderr(stderr):
This will typically be run on the result of the communicate() method
of a subprocess.Popen object.
"""
stderr = re.sub(br"\[\d+ refs\]\r?\n?", b"", stderr).strip()
stderr = re.sub(br"\[\d+ refs, \d+ blocks\]\r?\n?", b"", stderr).strip()
return stderr
def args_from_interpreter_flags():