Hi Noam

I think you should set breakpoints directly in the socket component (or even add some test code) to (maybe ;-)) see what happens.

Define a global flag F: boolean

In your code:
Before you assign values to ip and port
1. set F to true.
2. set a tag number for your socket, f.e. yoursocket.tag = 1234

Before you call connect
1. reset the F to false.

In the Socket component:
Wherever the ip or port are set to '' set a breakpoint with condition (F=true) AND (tag=1234).

Best regards

Message: 1
Date: Tue, 28 Jan 2014 23:17:43 +0200
From: "Noam weissman" <n...@silrd.com>
To: "ICS support mailing" <twsocket@lists.elists.org>
Subject: Re: [twsocket] TWSocket strange problem
Content-Type: text/plain; charset="ISO-8859-1"


Yes I run a few examples before using the components.

My current application has actually a few sockets.

I have a ping component checking if devices are online/offline. This is in its
own thread.

I have two sockets one for sending and one for receiving working in a separate
module with their own thread.

The socket that I have problems with is running in a separate thread

I added a testing code after assigning the Port and Addr, Something like this:

if((Socket->Addr == NULL) || (Socket->Port == 0))

And that was before even calling Connect...

Once in a few run's I got one of the above 0 or even both ?

I am sure that I am writing the port and IP values.


To unsubscribe or change your settings for TWSocket mailing list
please goto http://lists.elists.org/cgi-bin/mailman/listinfo/twsocket
Visit our website at http://www.overbyte.be

Reply via email to