Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

DarkBASIC Professional Discussion / DarkNET weirdest problem ever.

Author
Message
jeffhuys
20
Years of Service
User Offline
Joined: 24th May 2006
Location: No cheesy line here.
Posted: 18th Aug 2010 14:53 Edited at: 18th Aug 2010 15:02
Hi,
I'm designing a server and client with DarkNET, but even with this small code:


I get an error stating "An error occurred in mnGetInt whilst getting data from a packet. The end of the packet was reached before all data could be extracted from the packet."

As you can see, I have absolutely no code whatsoever that uses "mn Get Int".
Can anybody explain?

Thanks,

Jeff

EDIT: After a reboot, it worked. But for how long...?
EDIT2: Still some weird things. I think something/someone is sending packages to my pc?

Interplanetary Funk
16
Years of Service
User Offline
Joined: 19th Apr 2010
Location: Ipswich, United Kingdom
Posted: 18th Aug 2010 15:00
try this:


With your code I got a tcp error, when I set it to that it worked fine.
jeffhuys
20
Years of Service
User Offline
Joined: 24th May 2006
Location: No cheesy line here.
Posted: 18th Aug 2010 15:03
@PlanetaryFunk:
Thanks, but that gives me the same errors. My server (with more code) is acting weird too. The first player that connects is player 3... Then I disconnect and reconnect and the server crashes.

Interplanetary Funk
16
Years of Service
User Offline
Joined: 19th Apr 2010
Location: Ipswich, United Kingdom
Posted: 18th Aug 2010 15:06
Have a look here: http://en.wikipedia.org/wiki/List_of_TCP_and_UDP_port_numbers

The ports may be being used by another program, apparently all of these use ports 5555:
Quote: "Freeciv versions up to 2.0, Hewlett-Packard Data Protector, McAfee EndPoint Encryption Database Server, SAP"
jeffhuys
20
Years of Service
User Offline
Joined: 24th May 2006
Location: No cheesy line here.
Posted: 18th Aug 2010 15:09 Edited at: 18th Aug 2010 15:10
@PlanetaryFunk:
That seemed to do the trick!
Changed to 5557, which isn't in use, and no errors!
My theory was correct (I believe), because after leaving the server on for 3+ minutes, I got an error stating the buffers were full!

Thanks!

Interplanetary Funk
16
Years of Service
User Offline
Joined: 19th Apr 2010
Location: Ipswich, United Kingdom
Posted: 18th Aug 2010 15:16
NP. I've needed plenty of help setting up a DarkNet server myself, so I've picked up a couple of things.
Michael P
20
Years of Service
User Offline
Joined: 6th Mar 2006
Location: London (UK)
Posted: 19th Aug 2010 22:14
[quote]I get an error stating "An error occurred in mnGetInt whilst getting data from a packet. The end of the packet was reached before all data could be extracted from the packet."[quote]
This error means you are trying to read data in a packet that isn't there e.g. I send a packet with 3 integers in it and then try to read 4 on the receiving end. When trying to read the 4th integer this error will appear.

jeffhuys
20
Years of Service
User Offline
Joined: 24th May 2006
Location: No cheesy line here.
Posted: 19th Aug 2010 22:31
Quote: "This error means you are trying to read data in a packet that isn't there e.g. I send a packet with 3 integers in it and then try to read 4 on the receiving end. When trying to read the 4th integer this error will appear."


I know. But the problem is that I didn't read ANYTHING yet!
Turned out I had my uTorrent (not a pirate, chill ) on at port 5555... The same as my game.

Michael P
20
Years of Service
User Offline
Joined: 6th Mar 2006
Location: London (UK)
Posted: 19th Aug 2010 22:54
Ah right that makes sense, you probably had clients connecting to DarkNet sending unexpected data.

Login to post a reply

Server time is: 2026-07-25 17:49:27
Your offset time is: 2026-07-25 17:49:27