]>
jfr.im git - irc/quakenet/newserv.git/blob - nick/nickalloc.c
1 /* nick/host/realname/authname allocator */
4 #include "../core/nsmalloc.h"
9 /* Hosts and realname structures are the same size */
10 /* This assumption is checked in initnickalloc(); */
12 realname
*newrealname() {
13 return (realname
*)newhost();
16 void freerealname(realname
*rn
) {
21 return nsmalloc(POOL_NICK
, sizeof(nick
));
24 void freenick(nick
*np
) {
25 nsfree(POOL_NICK
, np
);
29 return nsmalloc(POOL_NICK
, sizeof(host
));
32 void freehost(host
*hp
) {
33 nsfree(POOL_NICK
, hp
);