From 7c8d76fad34cbb75b9f7faec156e88632631f127 Mon Sep 17 00:00:00 2001
From: Paul Sokolovsky <pfalcon@users.sourceforge.net>
Date: Sat, 18 Jun 2016 00:36:13 +0300
Subject: [PATCH] unix/alloc: Make coverage build and its overzealous warnings
 happy.

---
 unix/alloc.c | 7 +++++++
 1 file changed, 7 insertions(+)

diff --git a/unix/alloc.c b/unix/alloc.c
index 72b9d2a87..04c635ee9 100644
--- a/unix/alloc.c
+++ b/unix/alloc.c
@@ -86,6 +86,12 @@ void mp_unix_mark_exec(void) {
 }
 
 #if MICROPY_FORCE_PLAT_ALLOC_EXEC
+// Provide implementation of libffi ffi_closure_* functions in terms
+// of the functions above. On a normal Linux system, this save a lot
+// of code size.
+void *ffi_closure_alloc(size_t size, void **code);
+void ffi_closure_free(void *ptr);
+
 void *ffi_closure_alloc(size_t size, void **code) {
     mp_uint_t dummy;
     mp_unix_alloc_exec(size, code, &dummy);
@@ -93,6 +99,7 @@ void *ffi_closure_alloc(size_t size, void **code) {
 }
 
 void ffi_closure_free(void *ptr) {
+    (void)ptr;
     // TODO
 }
 #endif
-- 
GitLab