From 96fa1b7327b35cdeca6c77f2fdde906cabc437d8 Mon Sep 17 00:00:00 2001 From: Dirk Engling Date: Sat, 24 Oct 2026 20:30:30 +0200 Subject: Replace custom int64 with its standardized int64_t type --- opentracker.c | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) (limited to 'opentracker.c') diff --git a/opentracker.c b/opentracker.c index 8a39bde..af336aa 100644 --- a/opentracker.c +++ b/opentracker.c @@ -156,7 +156,7 @@ static ssize_t header_complete(char *request, ssize_t byte_count) { return 0; } -static void handle_dead(const int64 sock) { +static void handle_dead(const int64_t sock) { struct http_data *cookie = io_getcookie(sock); if (cookie) { size_t i; @@ -171,7 +171,7 @@ static void handle_dead(const int64 sock) { io_close(sock); } -static void handle_read(const int64 sock, struct ot_workstruct *ws) { +static void handle_read(const int64_t sock, struct ot_workstruct *ws) { struct http_data *cookie = io_getcookie(sock); ssize_t byte_count = io_tryread(sock, ws->inbuf, G_INBUF_SIZE); @@ -215,7 +215,7 @@ static void handle_read(const int64 sock, struct ot_workstruct *ws) { } } -static void handle_write(const int64 sock) { +static void handle_write(const int64_t sock) { struct http_data *cookie = io_getcookie(sock); size_t i; int chunked = 0; @@ -227,7 +227,7 @@ static void handle_write(const int64 sock) { for (i = 0; i < cookie->batches; ++i) { if (cookie->batch[i].bytesleft) { - int64 res = iob_send(sock, cookie->batch + i); + int64_t res = iob_send(sock, cookie->batch + i); if (res == -3) { handle_dead(sock); @@ -250,9 +250,9 @@ static void handle_write(const int64 sock) { handle_dead(sock); } -static void handle_accept(const int64 serversocket) { +static void handle_accept(const int64_t serversocket) { struct http_data *cookie; - int64 sock; + int64_t sock; ot_ip6 ip; uint16 port; tai6464 t; @@ -305,7 +305,7 @@ static void *server_mainloop(void *args) { random_bytes(ws.rand48_state, sizeof(ws.rand48_state)); for (;;) { - int64 sock; + int64_t sock; io_wait(); @@ -339,7 +339,7 @@ static void *server_mainloop(void *args) { } static int64_t ot_try_bind(ot_ip6 ip, uint16_t port, PROTO_FLAG proto) { - int64 sock = proto == FLAG_TCP ? socket_tcp6() : socket_udp6(); + int64_t sock = proto == FLAG_TCP ? socket_tcp6() : socket_udp6(); #ifdef _DEBUG { -- cgit v1.3