Displaying 1 result from an estimated 1 matches for "2ff17dd".
Did you mean:
24f179dd
2020 Sep 08
0
[libnbd PATCH] hack for testing python closure leaks: NOT FOR COMMIT
Just posting this for posterity, on something I used to track down
memory leaks related to python closures.
---
generator/Python.ml | 19 +++++++++++++++++++
1 file changed, 19 insertions(+)
diff --git a/generator/Python.ml b/generator/Python.ml
index 4a96cf6..2ff17dd 100644
--- a/generator/Python.ml
+++ b/generator/Python.ml
@@ -578,9 +578,27 @@ let generate_python_methods_c () =
pr " PyObject *buf; /* Optional pointer to persistent buffer. */\n";
pr "};\n";
pr "\n";
+ pr "static size_t alloc_count;\n";
+ pr...