From db9f3b5209a53cc3683dcb271b8b6e502b8d9bb3 Mon Sep 17 00:00:00 2001 From: Joshua Suskalo Date: Thu, 16 Sep 2021 14:09:29 -0500 Subject: [PATCH] Return nil if find-symbol fails --- src/coffi/ffi.clj | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/coffi/ffi.clj b/src/coffi/ffi.clj index a128b07..2cbb4b7 100644 --- a/src/coffi/ffi.clj +++ b/src/coffi/ffi.clj @@ -416,7 +416,7 @@ (defn- find-symbol "Gets the [[MemoryAddress]] of a symbol from the loaded libraries." [sym] - (.. (CLinker/systemLookup) (lookup sym) (get))) + (.. (CLinker/systemLookup) (lookup sym) (orElse nil))) (defn- method-type "Gets the [[MethodType]] for a set of `args` and `ret` types."