This repository has been archived on 2021-12-16. You can view files and clone it, but cannot push or open issues or pull requests.
lemonbbs/src/connlist.h
2021-12-16 22:16:13 +01:00

19 lines
422 B
C

#ifndef CHATSERVER_CONNLIST_H
#define CHATSERVER_CONNLIST_H
#include <stdint.h>
#include "oslib.h"
struct Connection {
uint8_t state;
struct LemonClientSocket socket;
int64_t userId; // -1 if not logged in
char username[64]; // to reduce db calls
};
struct Connection* allocateConnection();
void deallocateConnection(struct Connection* connection);
void initConnList(unsigned int maxConnCount);
#endif