Thread View: borland.public.cppbuilder.nativeapi
3 messages
3 total messages
Started by Eyyub Volkan �ektimur
Mon, 19 Nov 2007 13:36
HEAP sharing between EXE & DLL
Author: Eyyub Volkan �ektimur
Date: Mon, 19 Nov 2007 13:36
Date: Mon, 19 Nov 2007 13:36
16 lines
1577 bytes
1577 bytes
Hi, if i understood correctly, when your EXE & DLL heaps differs from each other, then you should not create memory at EXE and delete at DLL (or vice versa...). so, when you set them to use/share same HEAP, there will be no problems i guess... To do this with borland, set application/DLL to use dynamic version of RTL. Is it correct that when we use dynamic version of RTL , there will be no HEAP problem in the future, means you can mix memory management with DLL & EXE. Is there any way to understand that DLL & EXE are using the same HEAP or different HEAPs ? thanks for help _______________________ Eyyub Volkan �ektimur
Re: HEAP sharing between EXE & DLL
Author: Bob Gonder
Date: Mon, 19 Nov 2007 16:08
Date: Mon, 19 Nov 2007 16:08
12 lines
1403 bytes
1403 bytes
Eyyub Volkan �ektimur wrote: >Is it correct that when we use dynamic version of >RTL , there will be no HEAP problem in the future, means you can mix memory >management with DLL & EXE. No. For instance, if the exe is compiled with VS, they won't be using the same memory manager. Also if the exe is a different version of Borland/CodeGear than the dll, they might use different managers as well. You need to be very carefull, forever, whenever you circumvent the rules.
Re: HEAP sharing between EXE & DLL
Author: Eyyub Volkan �ektimur
Date: Tue, 20 Nov 2007 06:36
Date: Tue, 20 Nov 2007 06:36
25 lines
1943 bytes
1943 bytes
oh yes, i thought that but didn't write it. it's also required to use same version of RTL/CRT on EXE/DLL's. thank you for warning. I need to understand that are EXE & DLL's using the same memory manager/HEAP ? to avoid some problems, and make more reliable debugging... "Bob Gonder" <notbg@notmindspring.invalid> wrote in message news:ipc3k3hbvq8pfjivle4l1cn5etuong459b@4ax.com... > Eyyub Volkan �ektimur wrote: > >>Is it correct that when we use dynamic version of >>RTL , there will be no HEAP problem in the future, means you can mix >>memory >>management with DLL & EXE. > > No. > For instance, if the exe is compiled with VS, they won't be using the same > memory manager. > Also if the exe is a different version of Borland/CodeGear than the dll, > they might use > different managers as well. > > You need to be very carefull, forever, whenever you circumvent the rules. > >
Thread Navigation
This is a paginated view of messages in the thread with full content displayed inline.
Messages are displayed in chronological order, with the original post highlighted in green.
Use pagination controls to navigate through all messages in large threads.
Back to All Threads