away stuff from ratbox3
This commit is contained in:
parent
1b95ca0b6a
commit
ece36b7b5d
|
@ -609,4 +609,7 @@ extern void close_connection(struct Client *);
|
||||||
extern void init_uid(void);
|
extern void init_uid(void);
|
||||||
extern char *generate_uid(void);
|
extern char *generate_uid(void);
|
||||||
|
|
||||||
|
void allocate_away(struct Client *);
|
||||||
|
void free_away(struct Client *);
|
||||||
|
|
||||||
#endif /* INCLUDED_client_h */
|
#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
|
void
|
||||||
init_uid(void)
|
init_uid(void)
|
||||||
{
|
{
|
||||||
|
|
Loading…
Reference in New Issue