mirror of
https://github.com/matrix-construct/construct
synced 2024-12-25 23:14:13 +01:00
hash.c: Save some more bytes
This commit is contained in:
parent
909346edb7
commit
aa7eff28f2
3 changed files with 6 additions and 6 deletions
|
@ -82,7 +82,7 @@ extern void add_to_id_hash(const char *, struct Client *);
|
|||
extern void del_from_id_hash(const char *name, struct Client *client);
|
||||
extern struct Client *find_id(const char *name);
|
||||
|
||||
extern struct Channel *get_or_create_channel(struct Client *client_p, const char *chname, int *isnew);
|
||||
extern struct Channel *get_or_create_channel(struct Client *client_p, const char *chname, bool *isnew);
|
||||
extern void del_from_channel_hash(const char *name, struct Channel *chan);
|
||||
extern struct Channel *find_channel(const char *name);
|
||||
|
||||
|
|
|
@ -405,7 +405,7 @@ find_channel(const char *name)
|
|||
* block, if it didn't exist before).
|
||||
*/
|
||||
struct Channel *
|
||||
get_or_create_channel(struct Client *client_p, const char *chname, int *isnew)
|
||||
get_or_create_channel(struct Client *client_p, const char *chname, bool *isnew)
|
||||
{
|
||||
struct Channel *chptr;
|
||||
int len;
|
||||
|
@ -434,12 +434,12 @@ get_or_create_channel(struct Client *client_p, const char *chname, int *isnew)
|
|||
if (chptr != NULL)
|
||||
{
|
||||
if (isnew != NULL)
|
||||
*isnew = 0;
|
||||
*isnew = false;
|
||||
return chptr;
|
||||
}
|
||||
|
||||
if(isnew != NULL)
|
||||
*isnew = 1;
|
||||
*isnew = true;
|
||||
|
||||
chptr = allocate_channel(s);
|
||||
chptr->channelts = rb_current_time(); /* doesn't hurt to set it here */
|
||||
|
|
|
@ -395,7 +395,7 @@ ms_join(struct MsgBuf *msgbuf_p, struct Client *client_p, struct Client *source_
|
|||
static struct Mode mode;
|
||||
time_t oldts;
|
||||
time_t newts;
|
||||
int isnew;
|
||||
bool isnew;
|
||||
bool keep_our_modes = true;
|
||||
rb_dlink_node *ptr, *next_ptr;
|
||||
|
||||
|
@ -512,7 +512,7 @@ ms_sjoin(struct MsgBuf *msgbuf_p, struct Client *client_p, struct Client *source
|
|||
bool keep_our_modes = true;
|
||||
bool keep_new_modes = true;
|
||||
int fl;
|
||||
int isnew;
|
||||
bool isnew;
|
||||
int mlen_uid;
|
||||
int len_uid;
|
||||
int len;
|
||||
|
|
Loading…
Reference in a new issue