Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

Geek Culture / Dll which close the program...

Author
Message
Darktib
17
Years of Service
User Offline
Joined: 18th Jun 2007
Location: France
Posted: 25th Oct 2007 23:32
Hello,

I am coding my astar dll, but some functions closes the dbp program... So I don't understand... why a dll can close a program?
and how I have to do to avoid this strange result?

Thanks in advance,

~Darktib

RTS game project : 3.2% finished
|||%
Darktib
17
Years of Service
User Offline
Joined: 18th Jun 2007
Location: France
Posted: 26th Oct 2007 13:34
Can you help on this point? It is very important.
I have forget to tell you that the functions closes the program randomly. I think it is because of the dynamical allocation, but I'm not sure.

Thanks

~Darktib

RTS game project : 3.2% finished
|||%
Insert Name Here
17
Years of Service
User Offline
Joined: 20th Mar 2007
Location: Worcester, England
Posted: 26th Oct 2007 14:24
May I reccomend you post this in DLL talk.

Have I been given like a three year nobbslap?

demons breath
21
Years of Service
User Offline
Joined: 4th Oct 2003
Location: Surrey, UK
Posted: 26th Oct 2007 14:29
Try asking on the programming for all languages style thing.

And try and isolate which commands it is.

http://jamesmason01.googlepages.com/index.htm
Ron Erickson
Moderator
21
Years of Service
User Offline
Joined: 6th Dec 2002
Location: Pittsburgh, PA, USA
Posted: 26th Oct 2007 15:26
There is probably something in the dll trying to access an invalid pointer. Problems with a dll WILL cause the app to crash!


a.k.a WOLF!
Darktib
17
Years of Service
User Offline
Joined: 18th Jun 2007
Location: France
Posted: 27th Oct 2007 00:05
Thank you for your answers

The problem is that the program closes without any message of windows... so I can't think it is an invalid pointer...
And the functions which close the program are the function which free the dll and the function which search a path... (it is randomly - that means that the program close '1 time of 2' - please excuse my bad english)

RTS game project : 3.2% finished
|||%
Aaron Miller
18
Years of Service
User Offline
Joined: 25th Feb 2006
Playing: osu!
Posted: 28th Oct 2007 00:28
@Darktib
That smells of invalid pointers, VERY much. Either through your program or DBP. Check if you are returning a temporary address to anything anywhere in your program.

In addition, a DLL will close a program because the DLL (From my understanding) get's "attached" to that program's memory, and executed as part of that program. And when a DLL is freed, it is "detached" from that programs memory, and that memory freed. Where as the function pointers are just relative to where the program was loaded and where the DLL is in memory.


Cheers,

-naota

DBP, $80. DBP's plugins, $320. Watching DBP Crash, Priceless.
NG Website Aex.Uni forums
Eevil Weevil
17
Years of Service
User Offline
Joined: 1st Aug 2007
Location: Wherever you are, I wil follow
Posted: 28th Oct 2007 09:58
Oh, so that's why it closed down the application when I typed in:
Fill Memory 0,0,1000000000000000
Oops

Your signature has been erased by a forum hacke - I mean, a mod

Aaron Miller
18
Years of Service
User Offline
Joined: 25th Feb 2006
Playing: osu!
Posted: 28th Oct 2007 10:09
@Eevil Weevil
I seriously hope you're joking.... I really do...

DBP, $80. DBP's plugins, $320. Watching DBP Crash, Priceless.
NG Website Aex.Uni forums
Darktib
17
Years of Service
User Offline
Joined: 18th Jun 2007
Location: France
Posted: 4th Nov 2007 14:53
Thank you for your answers.

I did a dynamical allocation width malloc and realloc, width globals arrays, and I think the reallocation was very 'bugged'.
So I use now std::vector... I think that width this class my dll will not close the program.

@Insert Name Here:
Quote: "
May I reccomend you post this in DLL talk."

I am the author of the dll so I can't post about that in the dll talk

RTS game project : 3.2% finished
|||%
bitJericho
22
Years of Service
User Offline
Joined: 9th Oct 2002
Location: United States
Posted: 4th Nov 2007 15:29
Quote: ""width""


I think you meant "with". I don't normally comment on spelling/grammar, but that was really hard to read!


The greatest multiplayer text adventure ever...
Darktib
17
Years of Service
User Offline
Joined: 18th Jun 2007
Location: France
Posted: 4th Nov 2007 15:51
You are right, sorry for the mistake

RTS game project : 3.2% finished
|||%

Login to post a reply

Server time is: 2024-11-19 11:26:46
Your offset time is: 2024-11-19 11:26:46