Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

PING_REQUEST #151

Open
gvissers opened this issue Sep 7, 2021 · 0 comments
Open

PING_REQUEST #151

gvissers opened this issue Sep 7, 2021 · 0 comments
Labels

Comments

@gvissers
Copy link
Collaborator

gvissers commented Sep 7, 2021

In process_message_from_server(), a PING_REQUEST from the server is handled as

			// just send the pack back as it is
			my_tcp_send(in_data, data_length);

But this doesn't send the exact same package back, as in_data at that point contains the packet length, and my_tcp_send() will insert a new one. The resulting package that gets sent back thus looks like

{
    PING_REQUEST: u8,
    7: u16 , // (length = 1 byte opcode + 2 bytes old length + timestamp)
    5: u16,  // (incoming length as sent from server)
    timestamp: u32
}

I am assuming this is a bug, but it has been like that for a long time, so I'm checking if that's true. @raduprv , can you confirm that this needs fixing? (and if so, you must be getting some pretty wild ping times :D)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants