Cuberite Forum
Network API - Printable Version

+- Cuberite Forum (https://forum.cuberite.org)
+-- Forum: Cuberite (https://forum.cuberite.org/forum-4.html)
+--- Forum: Development (https://forum.cuberite.org/forum-13.html)
+--- Thread: Network API (/thread-1700.html)

Pages: 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15


RE: Network API - xoft - 01-12-2015

Please do. It's not yet in MCS itself, but if you build the self-tests, you can test it out on the EchoServer.
Code:
git checkout libevent
cmake -DSELF_TEST=1 .



RE: Network API - NiLSPACE - 01-12-2015

I suppose I have to compile it on my desktop, since you can't have VS 2013 on Windows XP.


RE: Network API - xoft - 01-12-2015

Yes. Also make sure that in the project settings, the platform toolset is set to Visual studio 2013 - Windows XP (v120_xp). I think I managed to set it via CMake, but never tested it.


RE: Network API - NiLSPACE - 01-12-2015

It works fine for me:
[Image: 7fc78806b9.png]


RE: Network API - xoft - 01-12-2015

Do you have IPv6 installed in that XP? Can you do a netstat -na while the server is running (we're interested in port 9876 on various interfaces)


RE: Network API - NiLSPACE - 01-13-2015

It took me a while to figure out how ports work with IPv6, but I managed to do it Smile
[Image: 103cf32e29.png]

Oh wait you want a netstat..

Here it is:
[Image: d42ed515bb.png]


RE: Network API - xoft - 01-13-2015

It looks as if port 9876 is not listed in the IPv4 address space. Can you telnet to the IPv4 address of the machine and does it echo back whatever you type?
Code:
telnet 192.168.80.131 9876
(The IP I used is based on your netstat listing, it may change if it's dynamic, check for the current value first)


RE: Network API - NiLSPACE - 01-13-2015

You're right. I'm not able to connect using the IPv4 address. Weird.

And now 127.0.0.1 doesn't work either. I'm restarting Windows XP to see if it fixes it.

No that didn't work Sad


RE: Network API - xoft - 01-13-2015

Stupid me, I had one condition wrong. Please update to 896f0bdc9f2c79da429a2506cc1dcdca7191e1b8 and retry. I've also added some debugging logging.


RE: Network API - NiLSPACE - 01-13-2015

None of the IP adresses work for me now. Also the console gives this on startup:
Code:
EchoServer: starting up
setsockopt(IPV6_V6ONLY) returned -1, err is 10042 (Een onbekende, ongeldige of niet-ondersteunde optie of niveau is opgegeven in een getsockopt- of setsockopt-aanroep.). Second socket will be created
Creating a second socket for IPv4
Press enter to close the server.

If I translate the Dutch part it says: "An unknown, invalid or not supported option or level is given in a getsockopt- or setsockopt- call"