datamodule in DLL Connect Oracle close report 10093 error

Discussion of open issues, suggestions and bugs regarding UniDAC (Universal Data Access Components) for Delphi, C++Builder, Lazarus (and FPC)
Post Reply
c123321
Posts: 20
Joined: Sat 03 Jul 2010 03:24

datamodule in DLL Connect Oracle close report 10093 error

Post by c123321 » Mon 07 Nov 2011 03:47

datamodule in DLL when Connect SQL is Ok, but when Connect Oracle if the test dll form close
report 10093 closesocket wsastartup error;

1: delphi2007 +unidac402;
2: Project14.dpr is a DLL project with datamodule and connect db by read ini file "MistoXsConfig.ini"
3: Project15.dpr is a exe project to test Project14.dll;
4: modify "MistoXsConfig.ini" to connect sql is ok, connect oracle and restart then close, the error displayed

if need leave email i can send the project,thanks

AlexP
Devart Team
Posts: 5530
Joined: Tue 10 Aug 2010 11:35

Post by AlexP » Tue 08 Nov 2011 07:59

Hello,

Please send your projects demonstrating the problem to alexp*devart*com.

AlexP
Devart Team
Posts: 5530
Joined: Tue 10 Aug 2010 11:35

Post by AlexP » Tue 08 Nov 2011 11:39

Hello,

Thank you for the information.
We have reproduced the problem.
We will try to fix it in the nearest product version.

c123321
Posts: 20
Joined: Sat 03 Jul 2010 03:24

Post by c123321 » Tue 08 Nov 2011 12:35

if the change not much, can you send me, i must used it write dll soon

AlexP
Devart Team
Posts: 5530
Joined: Tue 10 Aug 2010 11:35

Post by AlexP » Wed 16 Nov 2011 08:48

Hello,

We've investigated the problem more thoroughly and found out that such behaviour is connected with the specificity of the dll work.
It is not correct to set connection on DLL_PROCESS_ATTACH and break connection on DLL_PROCESS_DETACH, because on DLL_PROCESS_DETACH the process created by DataModule still exists, but the stream probably does not. That's why a more rational solution will be to create two methods in DLL – Connect and Disconnect – end set and break connection explicitly using them.

Post Reply