Add session pool
This commit is contained in:
24
src/session/session_pool.h
Normal file
24
src/session/session_pool.h
Normal file
@@ -0,0 +1,24 @@
|
||||
#ifndef _SESSION_POOL_H
|
||||
#define _SESSION_POOL_H
|
||||
|
||||
#ifdef __cpluscplus
|
||||
extern "C"
|
||||
{
|
||||
#endif
|
||||
|
||||
#include <stdint.h>
|
||||
|
||||
#include "session.h"
|
||||
|
||||
struct session_pool;
|
||||
struct session_pool *session_pool_create(uint64_t count);
|
||||
void session_pool_destroy(struct session_pool *pool);
|
||||
|
||||
struct session *session_pool_pop(struct session_pool *pool);
|
||||
void session_pool_push(struct session_pool *pool, struct session *sess);
|
||||
|
||||
#ifdef __cpluscplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif
|
||||
Reference in New Issue
Block a user