summaryrefslogtreecommitdiff
path: root/src/irc
diff options
context:
space:
mode:
authorPaul Townsend <pt@mindvox.org>2017-10-11 21:33:14 +0100
committerPaul Townsend <pt@mindvox.org>2017-10-11 21:33:14 +0100
commit87955b69cb82314becf1aa9f66c707705f517d0f (patch)
treedff6cd40cb246238b0e1a39ade6bcafc76a0edd9 /src/irc
parent016fd344362ddcc4b1a0781df9ac2416acc54e69 (diff)
downloadirssi-87955b69cb82314becf1aa9f66c707705f517d0f.zip
Add alternate_nick as a network-specific property.
Diffstat (limited to 'src/irc')
-rw-r--r--src/irc/core/irc-servers-setup.c9
1 files changed, 8 insertions, 1 deletions
diff --git a/src/irc/core/irc-servers-setup.c b/src/irc/core/irc-servers-setup.c
index 6040d3a5..a51ce2e2 100644
--- a/src/irc/core/irc-servers-setup.c
+++ b/src/irc/core/irc-servers-setup.c
@@ -69,7 +69,14 @@ static void sig_server_setup_fill_chatnet(IRC_SERVER_CONNECT_REC *conn,
return;
g_return_if_fail(IS_IRCNET(ircnet));
- if (ircnet->nick != NULL) g_free_and_null(conn->alternate_nick);
+ if (ircnet->nick != NULL) {
+ g_free_and_null(conn->nick);
+ conn->nick = g_strdup(ircnet->nick);
+ }
+ if (ircnet->alternate_nick != NULL) {
+ g_free_and_null(conn->alternate_nick);
+ conn->alternate_nick = g_strdup(ircnet->alternate_nick);
+ }
if (ircnet->usermode != NULL) {
g_free_and_null(conn->usermode);
conn->usermode = g_strdup(ircnet->usermode);