diff options
author | fadhil riyanto <me@fadev.org> | 2024-10-05 18:53:48 +0700 |
---|---|---|
committer | fadhil riyanto <me@fadev.org> | 2024-10-05 18:53:48 +0700 |
commit | ffe2e2cc6df63c5abed7db7d7d5901681fefe791 (patch) | |
tree | 63243271d2b0d833e13034c68ee3515ec08bad55 | |
parent | ca2ec97c4ae4353cf30d765987975789d367d494 (diff) |
fix network to host order
Signed-off-by: fadhil riyanto <me@fadev.org>
-rw-r--r-- | main2.c | 4 |
1 files changed, 2 insertions, 2 deletions
@@ -572,9 +572,9 @@ static int start_unpack_packet_no_epl(int fd, void* reserved, struct socks5_sess struct next_req_ipv4 *next_req = (struct next_req_ipv4*)buf; - printf("SOCKS_REQ ver: %c; CMD: %s; type: %s; ip: %u.%u.%u.%u:%u\n", buf[0], + printf("SOCKS_REQ ver: %c; CMD: %s; type: %s; ip: %u.%u.%u.%u:%d\n", buf[0], cmd2str(next_req->cmd), ip2str(buf[3]), next_req->dest[0], next_req->dest[1], next_req->dest[2], next_req->dest[3], - (uint16_t)next_req->port); + ntohs(next_req->port)); } // if1 |