Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

GdsConnection.Disconnect() (XdrStreams - send and receive must be disposed) [DNET188] #199

Closed
firebird-automations opened this issue Oct 11, 2008 · 7 comments

Comments

@firebird-automations
Copy link

Submitted by: @cincuranet

Jira_subtask_inward DNET179

@firebird-automations
Copy link
Author

Commented by: @cincuranet

6. GdsConnection.Disconnect()

the XdrStreams - send and receive must be disposed, but can not becouse it has been GC supressed,

in Disconnect we can GC.ReRegisterForFinalize disposed objects

public void Disconnect()
{
try
{
if (this.receive != null)
{
GC.ReRegisterForFinalize(this.receive);
this.receive.Close();
this.receive.Dispose();
}
if (this.send != null)
{
GC.ReRegisterForFinalize(this.send);
this.send.Close();
this.send.Dispose();
}
if (this.networkStream != null)
{
this.networkStream.Close();
}
if (this.socket != null)
{
this.socket.Close();
}

this.receive = null;
this.send = null;
this.socket = null;
this.networkStream = null;
}
catch (IOException)
{
throw;
}
}

@firebird-automations
Copy link
Author

Modified by: @cincuranet

Version: 2.5.0 Alpha 1 [ 10230 ]

Version: 2.1.0 [ 10102 ]

Version: 2.5.0 Alpha 2 [ 10240 ]

Fix Version: 2.5.0 Alpha 3 [ 10261 ]

Fix Version: 2.5.0 [ 10170 ]

Component: http://ADO.NET Provider [ 10041 ]

@firebird-automations
Copy link
Author

Modified by: @cincuranet

Version: 2.5.0 Alpha 2 [ 10240 ] =>

Version: 2.5.0 Alpha 1 [ 10230 ] =>

Fix Version: 2.5.0 Alpha 3 [ 10261 ] =>

Fix Version: 2.5.0 [ 10170 ] =>

@firebird-automations
Copy link
Author

Commented by: @cincuranet

These streams are not in 2.5 trunk.

@firebird-automations
Copy link
Author

Modified by: @cincuranet

status: Open [ 1 ] => Closed [ 6 ]

resolution: Won't Fix [ 2 ]

@firebird-automations
Copy link
Author

Modified by: @cincuranet

Link: This issue relate to DNET190 [ DNET190 ]

@firebird-automations
Copy link
Author

Modified by: @cincuranet

Link: This issue relate to DNET190 [ DNET190 ] =>

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants