away stuff from ratbox3
This commit is contained in:
parent
90840a2915
commit
300a543344
2 changed files with 20 additions and 0 deletions
|
@ -609,4 +609,7 @@ extern void close_connection(struct Client *);
|
|||
extern void init_uid(void);
|
||||
extern char *generate_uid(void);
|
||||
|
||||
void allocate_away(struct Client *);
|
||||
void free_away(struct Client *);
|
||||
|
||||
#endif /* INCLUDED_client_h */
|
||||
|
|
17
src/client.c
17
src/client.c
|
@ -1936,6 +1936,23 @@ free_user(struct User *user, struct Client *client_p)
|
|||
}
|
||||
}
|
||||
|
||||
void
|
||||
allocate_away(struct Client *client_p)
|
||||
{
|
||||
if(client_p->user->away == NULL)
|
||||
client_p->user->away = rb_bh_alloc(away_heap);
|
||||
}
|
||||
|
||||
|
||||
void
|
||||
free_away(struct Client *client_p)
|
||||
{
|
||||
if(client_p->user->away != NULL) {
|
||||
rb_bh_free(away_heap, client_p->user->away);
|
||||
client_p->user->away = NULL;
|
||||
}
|
||||
}
|
||||
|
||||
void
|
||||
init_uid(void)
|
||||
{
|
||||
|
|
Loading…
Reference in a new issue