summaryrefslogtreecommitdiff
path: root/python
diff options
context:
space:
mode:
Diffstat (limited to 'python')
-rw-r--r--python/samba/tests/segfault.py6
1 files changed, 6 insertions, 0 deletions
diff --git a/python/samba/tests/segfault.py b/python/samba/tests/segfault.py
index 6186d60c823..a2a42feffda 100644
--- a/python/samba/tests/segfault.py
+++ b/python/samba/tests/segfault.py
@@ -236,3 +236,9 @@ class SegfaultTests(samba.tests.TestCase):
c = ldb.Control(samdb, 'relax:1')
del c.critical
+
+ @segfault_detector
+ def test_random_bytes(self):
+ # memory error from SIZE_MAX -1 allocation.
+ from samba import generate_random_bytes
+ generate_random_bytes(-1)