hedgewars/uLandPainted.pas
changeset 5066 d2684b6f02ce
parent 4976 088d40d8aba2
child 6580 6155187bf599
--- a/hedgewars/uLandPainted.pas	Mon Mar 28 20:13:03 2011 -0400
+++ b/hedgewars/uLandPainted.pas	Tue Mar 29 16:24:55 2011 +0200
@@ -24,6 +24,7 @@
 
 procedure Draw;
 procedure initModule;
+procedure freeModule;
 
 implementation
 uses uLandGraphics, uConsts, uUtils, SDLh, uCommands, uDebug;
@@ -171,4 +172,16 @@
     RegisterVariable('draw', vtCommand, @chDraw, false);
 end;
 
+procedure freeModule;
+var pe, pp: PPointEntry;
+begin
+    pe:= pointsListHead;
+    while(pe <> nil) do
+        begin
+        pp:= pe;
+        pe:= pe^.next;
+        dispose(pp);
+        end;
+end;
+
 end.