From 58f339fe988d770da5de4ad7361a619b5deea2f6 Mon Sep 17 00:00:00 2001 From: Dadoum <24679280+Dadoum@users.noreply.github.com> Date: Fri, 11 Aug 2023 00:07:43 +0000 Subject: [PATCH] Dispose file handles when AndroidLibrary is destroyed --- lib/provision/androidlibrary.d | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/lib/provision/androidlibrary.d b/lib/provision/androidlibrary.d index 427cbb89..f3e19b07 100644 --- a/lib/provision/androidlibrary.d +++ b/lib/provision/androidlibrary.d @@ -173,6 +173,10 @@ public class AndroidLibrary { destroy(library); } + if (elfFile) { + destroy(elfFile); + } + if (allocation) { MmapAllocator.instance.deallocate((allocation.ptr - shift)[0..allocation.length + shift]); }