Long strings as out proc parameters not finalized
Original Reporter info from Mantis: FPCCore
-
Reporter name: FPC core team
Original Reporter info from Mantis: FPCCore
- Reporter name: FPC core team
Description:
Long strings as out procedure parameters ar not finalized, see program.
Heap dump:
Heap dump by heaptrc unit
16 memory blocks allocated : 883/904
15 memory blocks freed : 867/888
1 unfreed memory blocks : 16
True heap size : 262144 (16 used in System startup)
True free heap : 262048
Should be : 262056
Call trace for block $080A124C size 16
$08077266 NEWANSISTRING, line 72 of astrings.inc
$08077787 fpc_ansistr_setlength, line 440 of astrings.inc
Assembler listing:
P$PROJECT1_PROC$ANSISTRING: # Temps allocated between ebp-8 and ebp-4 pushl %ebp movl %esp,%ebp subl $8,%esp movl %ebx,-8(%ebp) # Para value located at ebp-4 movl %eax,-4(%ebp) .Ll2: .stabn 68,0,9,.Ll2 - P$PROJECT1_PROC$ANSISTRING movl -4(%ebp),%eax movl $0,(%eax) !!!!! nil -> str1, no finalize ..... ..... movl $U_P$PROJECT1_STR1,%eax call fpc_ansistr_setlength .Ll9: .stabn 68,0,19,.Ll9 - main # [19] proc(str1); movl $U_P$PROJECT1_STR1,%eax !!!!! no finalize call P$PROJECT1_PROC$ANSISTRING
Additional information:
Reporter: Martin Schreiber
EMail:
Mantis conversion info:
- Mantis ID: 5228
- OS: Linux
- Version: 1.9.4
- Fixed in version: 1.9.9