Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
louiz’
biboumi
Commits
112197f6
Commit
112197f6
authored
Feb 19, 2014
by
louiz’
Browse files
Fix the joined flag on channels, avoid sending the topic twice when joining
parent
8fd27466
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
2 additions
and
4 deletions
+2
-4
src/irc/irc_client.cpp
src/irc/irc_client.cpp
+2
-4
No files found.
src/irc/irc_client.cpp
View file @
112197f6
...
@@ -270,10 +270,7 @@ void IrcClient::on_channel_join(const IrcMessage& message)
...
@@ -270,10 +270,7 @@ void IrcClient::on_channel_join(const IrcMessage& message)
IrcChannel
*
channel
=
this
->
get_channel
(
chan_name
);
IrcChannel
*
channel
=
this
->
get_channel
(
chan_name
);
const
std
::
string
nick
=
message
.
prefix
;
const
std
::
string
nick
=
message
.
prefix
;
if
(
channel
->
joined
==
false
)
if
(
channel
->
joined
==
false
)
{
channel
->
set_self
(
nick
);
channel
->
joined
=
true
;
channel
->
set_self
(
nick
);
}
else
else
{
{
const
IrcUser
*
user
=
channel
->
add_user
(
nick
,
this
->
prefix_to_mode
);
const
IrcUser
*
user
=
channel
->
add_user
(
nick
,
this
->
prefix_to_mode
);
...
@@ -343,6 +340,7 @@ void IrcClient::on_channel_completely_joined(const IrcMessage& message)
...
@@ -343,6 +340,7 @@ void IrcClient::on_channel_completely_joined(const IrcMessage& message)
{
{
const
std
::
string
chan_name
=
utils
::
tolower
(
message
.
arguments
[
1
]);
const
std
::
string
chan_name
=
utils
::
tolower
(
message
.
arguments
[
1
]);
IrcChannel
*
channel
=
this
->
get_channel
(
chan_name
);
IrcChannel
*
channel
=
this
->
get_channel
(
chan_name
);
channel
->
joined
=
true
;
this
->
bridge
->
send_user_join
(
this
->
hostname
,
chan_name
,
channel
->
get_self
(),
this
->
bridge
->
send_user_join
(
this
->
hostname
,
chan_name
,
channel
->
get_self
(),
channel
->
get_self
()
->
get_most_significant_mode
(
this
->
sorted_user_modes
),
channel
->
get_self
()
->
get_most_significant_mode
(
this
->
sorted_user_modes
),
true
);
true
);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment