X-Git-Url: http://git.pk910.de/?a=blobdiff_plain;f=include%2Fclient.h;h=26f0481cdaf13a7e8a4704dc8ae44e90793d703c;hb=b3e7a2bbceb4d17cdab3ce7579fcaac2aa77868d;hp=aea930ab404da257135bb8b298e07cb618e0120c;hpb=f1acbdf96cb8c8094df4aaf8011b20c7332ba2d6;p=ircu2.10.12-pk.git diff --git a/include/client.h b/include/client.h index aea930a..26f0481 100644 --- a/include/client.h +++ b/include/client.h @@ -531,7 +531,7 @@ struct Client { #define HasFlag(cli, flag) FlagHas(&cli_flags(cli), flag) /** Return non-zero if the client is an IRC operator (global or local). */ -#define IsAnOper(x) (HasFlag(x, FLAG_OPER) || HasFlag(x, FLAG_LOCOP)) +#define IsAnOper(x) (IsOper(x) || IsLocOp(x)) /** Return non-zero if the client's connection is blocked. */ #define IsBlocked(x) HasFlag(x, FLAG_BLOCKED) /** Return non-zero if the client's connection is still being burst. */ @@ -555,8 +555,8 @@ struct Client { #define IsInvisible(x) HasFlag(x, FLAG_INVISIBLE) /** Return non-zero if the client caused a net.burst. */ #define IsJunction(x) HasFlag(x, FLAG_JUNCTION) -/** Return non-zero if the client has set mode +O (local operator). */ -#define IsLocOp(x) HasFlag(x, FLAG_LOCOP) +/** Return non-zero if the client has set mode +O (local operator) locally. */ +#define IsLocOp(x) (MyConnect(x) && HasFlag(x, FLAG_LOCOP)) /** Return non-zero if the client has set mode +o (global operator). */ #define IsOper(x) HasFlag(x, FLAG_OPER) /** Return non-zero if the client has an active UDP ping request. */ @@ -660,6 +660,8 @@ struct Client { #define ClearHiddenHost(x) ClrFlag(x, FLAG_HIDDENHOST) /** Clear the client's pending PING flag. */ #define ClearPingSent(x) ClrFlag(x, FLAG_PINGSENT) +/** Clear the client's HUB flag. */ +#define ClearHub(x) ClrFlag(x, FLAG_HUB) /* free flags */ #define FREEFLAG_SOCKET 0x0001 /**< socket needs to be freed */