diff options
author | Sébastien Helleu <flashcode@flashtux.org> | 2019-03-02 11:09:52 +0100 |
---|---|---|
committer | Sébastien Helleu <flashcode@flashtux.org> | 2019-03-02 11:09:52 +0100 |
commit | 2f5aa3b5097db7a0c475ab73e487a2af30a59b99 (patch) | |
tree | 7c069a770f4dae1f7ca2a65ae946c40d3b4572ad /src/plugins/relay | |
parent | 76290729b71debd8f3b442bf76c4599661815562 (diff) | |
download | weechat-2f5aa3b5097db7a0c475ab73e487a2af30a59b99.zip |
core: use bitwise shift operator to define flag constants
Diffstat (limited to 'src/plugins/relay')
-rw-r--r-- | src/plugins/relay/relay-raw.h | 12 | ||||
-rw-r--r-- | src/plugins/relay/weechat/relay-weechat-protocol.h | 8 |
2 files changed, 10 insertions, 10 deletions
diff --git a/src/plugins/relay/relay-raw.h b/src/plugins/relay/relay-raw.h index edefc7135..37bdc7b7e 100644 --- a/src/plugins/relay/relay-raw.h +++ b/src/plugins/relay/relay-raw.h @@ -24,13 +24,13 @@ #include "relay-client.h" -#define RELAY_RAW_BUFFER_NAME "relay_raw" -#define RELAY_RAW_PREFIX_RECV "-->" -#define RELAY_RAW_PREFIX_SEND "<--" +#define RELAY_RAW_BUFFER_NAME "relay_raw" +#define RELAY_RAW_PREFIX_RECV "-->" +#define RELAY_RAW_PREFIX_SEND "<--" -#define RELAY_RAW_FLAG_RECV 1 -#define RELAY_RAW_FLAG_SEND 2 -#define RELAY_RAW_FLAG_BINARY 4 +#define RELAY_RAW_FLAG_RECV (1 << 0) +#define RELAY_RAW_FLAG_SEND (1 << 1) +#define RELAY_RAW_FLAG_BINARY (1 << 2) struct t_relay_raw_message { diff --git a/src/plugins/relay/weechat/relay-weechat-protocol.h b/src/plugins/relay/weechat/relay-weechat-protocol.h index 4c8500074..76c90c8ce 100644 --- a/src/plugins/relay/weechat/relay-weechat-protocol.h +++ b/src/plugins/relay/weechat/relay-weechat-protocol.h @@ -20,10 +20,10 @@ #ifndef WEECHAT_PLUGIN_RELAY_WEECHAT_PROTOCOL_H #define WEECHAT_PLUGIN_RELAY_WEECHAT_PROTOCOL_H -#define RELAY_WEECHAT_PROTOCOL_SYNC_BUFFER 1 -#define RELAY_WEECHAT_PROTOCOL_SYNC_NICKLIST 2 -#define RELAY_WEECHAT_PROTOCOL_SYNC_BUFFERS 4 -#define RELAY_WEECHAT_PROTOCOL_SYNC_UPGRADE 8 +#define RELAY_WEECHAT_PROTOCOL_SYNC_BUFFER (1 << 0) +#define RELAY_WEECHAT_PROTOCOL_SYNC_NICKLIST (1 << 1) +#define RELAY_WEECHAT_PROTOCOL_SYNC_BUFFERS (1 << 2) +#define RELAY_WEECHAT_PROTOCOL_SYNC_UPGRADE (1 << 3) #define RELAY_WEECHAT_PROTOCOL_SYNC_ALL \ (RELAY_WEECHAT_PROTOCOL_SYNC_BUFFER | \ |