diff options
author | Ian Moffett <ian@osmora.org> | 2024-10-03 21:22:41 -0500 |
---|---|---|
committer | Ian Moffett <ian@osmora.org> | 2024-10-03 21:22:41 -0500 |
commit | 7f5b307413a29502791fb8cbe6209c0b0f5d2006 (patch) | |
tree | efb44f9f27580194c91857c9b3138b202ef9da29 /lib/include/server.h | |
parent | 85c4c48480c6f0aabcd8ccb38036392b71a05c2e (diff) |
server: Fix handling of multiple clients
Improve handling of multiple connected clients. This fixes issues related
to blocking of one client while another is connected as well as certain
race conditions.
Signed-off-by: Ian Moffett <ian@osmora.org>
Diffstat (limited to 'lib/include/server.h')
-rw-r--r-- | lib/include/server.h | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/lib/include/server.h b/lib/include/server.h index 52f92ce..1c23f61 100644 --- a/lib/include/server.h +++ b/lib/include/server.h @@ -34,6 +34,7 @@ #include <ostp/session.h> #include <pthread.h> #include <stddef.h> +#include <stdint.h> #define MAX_CLIENTS 32 @@ -41,6 +42,7 @@ struct ostp_client { struct ostp_session session; int sockfd; pthread_t td; + volatile uint8_t authed : 1; }; struct ostp_listener { |