diff options
author | Thomas Heller <theller@ctypes.org> | 2009-09-18 20:05:44 (GMT) |
---|---|---|
committer | Thomas Heller <theller@ctypes.org> | 2009-09-18 20:05:44 (GMT) |
commit | 6be522bfc268a3a49c7a605667a760dd4a09e43f (patch) | |
tree | 71c82690ef32e8cf6cb535ec6070071098cb7138 /Lib/ctypes/test | |
parent | 7a352c0ed8a12d868d9b682f4adf33f558d19855 (diff) | |
download | cpython-6be522bfc268a3a49c7a605667a760dd4a09e43f.zip cpython-6be522bfc268a3a49c7a605667a760dd4a09e43f.tar.gz cpython-6be522bfc268a3a49c7a605667a760dd4a09e43f.tar.bz2 |
Issue #4606: Passing 'None' if ctypes argtype is set to POINTER(...)
does now always result in NULL.
Diffstat (limited to 'Lib/ctypes/test')
-rw-r--r-- | Lib/ctypes/test/test_parameters.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/Lib/ctypes/test/test_parameters.py b/Lib/ctypes/test/test_parameters.py index 69db14f..82704d5 100644 --- a/Lib/ctypes/test/test_parameters.py +++ b/Lib/ctypes/test/test_parameters.py @@ -97,7 +97,7 @@ class SimpleTypesTestCase(unittest.TestCase): self.assertEqual(x.contents.value, 42) self.assertEqual(LPINT(c_int(42)).contents.value, 42) - self.assertEqual(LPINT.from_param(None), 0) + self.assertEqual(LPINT.from_param(None), None) if c_int != c_long: self.assertRaises(TypeError, LPINT.from_param, pointer(c_long(42))) |