Board index » delphi » INDY "Address Already In Use" Bug

INDY "Address Already In Use" Bug

INDY 9.1 / D5

Have both client and server in same application (TIdTCPClient and
TIdTCPServer based).

Client connects to server.  All's okay.
Client disconnects from server.  Still Okay.
Client attempts to reconnect - NOT Okay.  Receive "Address already in use"
exception and the client does not connect.

Terminate Delphi and try to reconnect.  Still no go.

I have tried setting ReuseSocket to both rsTrue and rsFalse with no apparent
effect.

I can not reconnect to the server until after I reboot the workstation.

Any ideas?

 

Re:INDY "Address Already In Use" Bug


Clarification...
    The bug exists when the component is placed on a form.  When created
dynamically, the problem doesn't seem to exist.

Charles

Quote
"Charles Stack" <char...@codycomp.com> wrote in message

news:3d0516dc$1_1@dnews...
Quote
> INDY 9.1 / D5

> Have both client and server in same application (TIdTCPClient and
> TIdTCPServer based).

> Client connects to server.  All's okay.
> Client disconnects from server.  Still Okay.
> Client attempts to reconnect - NOT Okay.  Receive "Address already in use"
> exception and the client does not connect.

> Terminate Delphi and try to reconnect.  Still no go.

> I have tried setting ReuseSocket to both rsTrue and rsFalse with no
apparent
> effect.

> I can not reconnect to the server until after I reboot the workstation.

> Any ideas?

Re:INDY "Address Already In Use" Bug


you mean something like this:

procedure TForm1.FormCreate(Sender: TObject);
begin
IdTCPClient1.Connect;
IdTCPClient1.Disconnect;
IdTCPClient1.Connect;
end;

with
IdTCPClient1.host=localhost
IdTCPServer1.defaultport=IdTCPClient1.port

--

Bas Gooijen

Quote
"Charles Stack" <char...@codycomp.com> wrote in message

news:3d051a06$1_1@dnews...
Quote
> Clarification...
>     The bug exists when the component is placed on a form.  When created
> dynamically, the problem doesn't seem to exist.

> Charles

> "Charles Stack" <char...@codycomp.com> wrote in message
> news:3d0516dc$1_1@dnews...
> > INDY 9.1 / D5

> > Have both client and server in same application (TIdTCPClient and
> > TIdTCPServer based).

> > Client connects to server.  All's okay.
> > Client disconnects from server.  Still Okay.
> > Client attempts to reconnect - NOT Okay.  Receive "Address already in
use"
> > exception and the client does not connect.

> > Terminate Delphi and try to reconnect.  Still no go.

> > I have tried setting ReuseSocket to both rsTrue and rsFalse with no
> apparent
> > effect.

> > I can not reconnect to the server until after I reboot the workstation.

> > Any ideas?

Re:INDY "Address Already In Use" Bug


Yup.

But, if the socket is created at runtime, the situtation doesn't exist.
Clearly a design-time issue.

cjs

Quote
"Bas Gooijen" <bas_gooi...@yahoo.com> wrote in message

news:3d05e2f8$1_2@dnews...
Quote
> you mean something like this:

> procedure TForm1.FormCreate(Sender: TObject);
> begin
> IdTCPClient1.Connect;
> IdTCPClient1.Disconnect;
> IdTCPClient1.Connect;
> end;

> with
> IdTCPClient1.host=localhost
> IdTCPServer1.defaultport=IdTCPClient1.port

> --

> Bas Gooijen

> "Charles Stack" <char...@codycomp.com> wrote in message
> news:3d051a06$1_1@dnews...
> > Clarification...
> >     The bug exists when the component is placed on a form.  When created
> > dynamically, the problem doesn't seem to exist.

> > Charles

> > "Charles Stack" <char...@codycomp.com> wrote in message
> > news:3d0516dc$1_1@dnews...
> > > INDY 9.1 / D5

> > > Have both client and server in same application (TIdTCPClient and
> > > TIdTCPServer based).

> > > Client connects to server.  All's okay.
> > > Client disconnects from server.  Still Okay.
> > > Client attempts to reconnect - NOT Okay.  Receive "Address already in
> use"
> > > exception and the client does not connect.

> > > Terminate Delphi and try to reconnect.  Still no go.

> > > I have tried setting ReuseSocket to both rsTrue and rsFalse with no
> > apparent
> > > effect.

> > > I can not reconnect to the server until after I reboot the
workstation.

> > > Any ideas?

Re:INDY "Address Already In Use" Bug


Quote
> But, if the socket is created at runtime, the situtation doesn't exist.
> Clearly a design-time issue.

1/ Are you using the latest version ?
2/ If yes, could you report it on sourceforge ? I'll look into it when I get
back home...

Thanks,
Stephane

Re:INDY "Address Already In Use" Bug


Yup.  Latest from the FTP server.  Will report it on sourceforge later
today.

cjs

Quote
"Stephane Grobety" <grob...@fulgan.com> wrote in message

news:Xns922AA075130D1grobetyfulgancom@207.105.83.65...
Quote
> > But, if the socket is created at runtime, the situtation doesn't exist.
> > Clearly a design-time issue.

> 1/ Are you using the latest version ?
> 2/ If yes, could you report it on sourceforge ? I'll look into it when I
get
> back home...

> Thanks,
> Stephane

Re:INDY "Address Already In Use" Bug


On 11 Jun 2002, "Charles Stack" <char...@codycomp.com> wrote in
news:3d060f04$1_2@dnews:

Quote
> Yup.  Latest from the FTP server.  Will report it on sourceforge later
> today.

Thanks.

Good luck,
Stephane

Re:INDY "Address Already In Use" Bug


... any work around?

Quote
"Charles Stack" <char...@codycomp.com> wrote in message

news:3d0516dc$1_1@dnews...
Quote
> INDY 9.1 / D5

> Have both client and server in same application (TIdTCPClient and
> TIdTCPServer based).

> Client connects to server.  All's okay.
> Client disconnects from server.  Still Okay.
> Client attempts to reconnect - NOT Okay.  Receive "Address already in use"
> exception and the client does not connect.

> Terminate Delphi and try to reconnect.  Still no go.

> I have tried setting ReuseSocket to both rsTrue and rsFalse with no
apparent
> effect.

> I can not reconnect to the server until after I reboot the workstation.

> Any ideas?

Re:INDY "Address Already In Use" Bug


As I mentioned in another post, the work around is to create the components
at runtime rather than at design-time.  This seems to work to just fine.

Charles

Quote
"Delphinoy" <delphi...@yahoo.com> wrote in message news:3d096357_1@dnews...
> ... any work around?

> "Charles Stack" <char...@codycomp.com> wrote in message
> news:3d0516dc$1_1@dnews...
> > INDY 9.1 / D5

> > Have both client and server in same application (TIdTCPClient and
> > TIdTCPServer based).

> > Client connects to server.  All's okay.
> > Client disconnects from server.  Still Okay.
> > Client attempts to reconnect - NOT Okay.  Receive "Address already in
use"
> > exception and the client does not connect.

> > Terminate Delphi and try to reconnect.  Still no go.

> > I have tried setting ReuseSocket to both rsTrue and rsFalse with no
> apparent
> > effect.

> > I can not reconnect to the server until after I reboot the workstation.

> > Any ideas?

Re:INDY "Address Already In Use" Bug


could you upload a sample to .attachments, or send me a sample, please

--

Bas Gooijen

Quote
"Charles Stack" <char...@codycomp.com> wrote in message

news:3d0a09ff$1_2@dnews...
Quote
> As I mentioned in another post, the work around is to create the
components
> at runtime rather than at design-time.  This seems to work to just fine.

> Charles

> "Delphinoy" <delphi...@yahoo.com> wrote in message

news:3d096357_1@dnews...
Quote
> > ... any work around?

> > "Charles Stack" <char...@codycomp.com> wrote in message
> > news:3d0516dc$1_1@dnews...
> > > INDY 9.1 / D5

> > > Have both client and server in same application (TIdTCPClient and
> > > TIdTCPServer based).

> > > Client connects to server.  All's okay.
> > > Client disconnects from server.  Still Okay.
> > > Client attempts to reconnect - NOT Okay.  Receive "Address already in
> use"
> > > exception and the client does not connect.

> > > Terminate Delphi and try to reconnect.  Still no go.

> > > I have tried setting ReuseSocket to both rsTrue and rsFalse with no
> > apparent
> > > effect.

> > > I can not reconnect to the server until after I reboot the
workstation.

> > > Any ideas?

Other Threads