patch 8.2.3620: memory leak reported in libtlib

Problem:    Memory leak reported in libtlib.
Solution:   Call del_curterm() when cleaning up memory.  Rename term.h to
            termdefs.h to avoid a name clash.
diff --git a/src/alloc.c b/src/alloc.c
index a2dc080..d0901f4 100644
--- a/src/alloc.c
+++ b/src/alloc.c
@@ -561,6 +561,7 @@
 # endif
 
     free_termoptions();
+    free_cur_term();
 
     // screenlines (can't display anything now!)
     free_screenlines();