El 24/11/21 a les 14:38, Luca Olivetti via lazarus ha escrit:
El 24/11/21 a les 14:29, Martin Frb via lazarus ha escrit:

I don't know where that message came from, but is there a way to see it while debugging the application under lazarus?

I would guess this is based on https://docs.microsoft.com/de-de/windows-hardware/drivers/debugger/gflags-and-pageheap

Now there are 2 modes: "standard" and "full"
Note: this is only about mem on the heap. Local vars on the stack are not affected (except, if (like objects) they are pointers to the heap, then the heap part (and only that) will be affected)

"Standard" only detects, overruns when mem is freed.
If I understand this correctly, in FPC you can enable -gh heaptrc, and this will do something similar, but limited...

Yes, I routinely do that, but it only works for pascal code. In this case it was a c dll (that I wrote as a bridge between another dll and my pascal code) so heaptrc wouldn't catch that error. I suppose the message comes from some windows core dll and windbg can display it, I don't know if and how gdb can (I'm not using fpdebug yet, maybe it can?).

btw, I'm not sure that gflags was doing anything: I was getting the same result with every flag activated as with none of them. In fact when I sent the first message in this thread I had no windows debugging tool installed, yet the debugger stopped on the free, only I couldn't see or find that message.

Bye
--
Luca Olivetti
Wetron Automation Technology http://www.wetron.es/
Tel. +34 93 5883004 (Ext.3010)  Fax +34 93 5883007
--
_______________________________________________
lazarus mailing list
lazarus@lists.lazarus-ide.org
https://lists.lazarus-ide.org/listinfo/lazarus

Reply via email to