Unsolved QTcpSocket and error
-
Hi! Are your firewalls shut down? MAC (SELinux, AppArmor, Tomoyo) disabled?
-
It's not a problème with firewall because it works in first case.
If I have used ip 192.168.0.x in first case for the server it works.
And if i swith the client and server on pc with the same address 192.168.0.x it doesn't work. -
Hi
How do you assign these ips?If you are on a network with dhcp you can't use what ever
ip you want for static.The correct way is to lower the range for automatically assigned ips on the dhcp router and
then use one of none shared ips for static.
Some routers can also do it based mac addresses. -
Hi
Thanks for your reply.There isn't dhcp because I have no router it's ad hoc network created under windows with cmd:
Netsh wlan start hostednetwork.
And I assign ip address with a command like that:
Netsh interface ip set address name="Wi-Fi" static 192.168.0.10 255.255.255.0. -
Ok it sounds like you know networking pretty well then.
So if its ad hoc, it seems unlikely that the ip be in use.
I have no further ideas it it seems u done ping test etc.Give it some days and see if others have better ideas.
-
Hi,
What port are you using ? Do you have anything else that might use it ?
-
The port used is 5555 but the comminucation works well.
PC A (Server) => 192.168.0.10
PC B (Client) => 192.168.0.20OK
but if i swith server and client.
PC B (Server) => 192.168.0.10
PC A (Client) => 192.168.0.20The connection can be established.
If i change the ip of server in this configuration
PC B (Server) => 192.168.0.11
PC A (Client) => 192.168.0.20it'll work ? But i don't know why.
-
Than a silly question, did you check that the port is not still opened ?
-
How can i do that ? with listening ?
-
netstat
would likely be more appropriate