From 6aaf3bb3911d2e08c0eabab8e1106198207f4baa Mon Sep 17 00:00:00 2001 From: richard Date: Sat, 23 Jul 2022 02:22:49 +0100 Subject: [PATCH] autoconvert None to ffi.NULL --- pyray/__init__.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/pyray/__init__.py b/pyray/__init__.py index 7e2a312..69177cc 100644 --- a/pyray/__init__.py +++ b/pyray/__init__.py @@ -57,6 +57,8 @@ def makefunc(a): arg = ffi.addressof(arg) elif str(type(arg)) == "" and "*" not in str(arg): #Pypy arg = ffi.addressof(arg) + elif arg is None: + arg = ffi.NULL modified_args.append(arg) result = a(*modified_args) if result is None: