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

Network byte order in message packets #1

Closed
wangyisong1996 opened this issue May 5, 2018 · 0 comments
Closed

Network byte order in message packets #1

wangyisong1996 opened this issue May 5, 2018 · 0 comments

Comments

@wangyisong1996
Copy link
Collaborator

Pls convert msg.hdr.length to network byte order.

msg.hdr.type = REQUEST;
msg.hdr.length = length;
if (send(sockfd, &msg, length + sizeof(struct Header), 0) == -1) {
    LOG("Failed to forward message: %s.\n", strerror(errno));
}
@ring00 ring00 closed this as completed May 24, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants