lazarus custom CGI application memory leak. lazarus / 38-Networking and Web Programming ---------------------------------------------------------------------- BSaidus · 2023-10-14 04:19 Hello. Trying to learn more about CGI application on lazarus/fpc, I created an empty Custom CGI application. Compiled project in debug mode with heaptrc activated and execute it without using a web server ( just in console). The result is a memory leak Code: [Select]Heap dump by heaptrc unit of "C:\GNU\fpc331\projects\cgi\lib\i386-win32\cgiproject1.exe" 4272 memory blocks allocated : 269213/286576 4241 memory blocks freed     : 266968/284240 31 unfreed memory blocks : 2245 True heap size : 851968 (320 used in System startup) True free heap : 845904 Should be : 846336 Call trace for block $01771408 size 16   $00435FB2   $0041...   ... The project tested on 2 lazarus/fpc flavours. Lazarus version: 2.2.7 / FPC 3.2.3 ( Fixes ). Lazarus version: 3.0RC1 / FPC 3.3.1 ( trunk). Thanks. ---------------------------------------------------------------------- Warfley · 2023-10-14 06:47 I think there once was a discussion in this forum about this, with the result being: yes it leaks, but that's no problem because the process will anyway only Hadley one request before shutting down. ---------------------------------------------------------------------- BSaidus · 2023-10-14 09:48 Yep, I found the thread. https://forum.lazarus.freepascal.org/index.php/topic,64075.msg487175.h tml#msg487175