Commit Graph

670 Commits

Author SHA1 Message Date
John Reese
9aff0cd566 See #1147: show new server name when jumping
This updates the connect command in *status to retrieve the next server
object before triggering the jump, thereby allowing it to display the
next server's name rather than a generic message.
2015-10-25 12:41:00 -07:00
Alexey Sokolov
933aa6db0c Add some more tests and fix a bug which sometimes blocked login of users.
This bug wasn't released yet.
cc @jpnurmi
2015-10-18 23:22:32 +01:00
Alexey Sokolov
f3762e8b05 Use termios instead of deprecated getpass().
Also this fixes flaky integration test. Sometimes it hanged because
getpass() sometimes didn't want to believe that it already got the
password from input.
2015-10-16 23:33:11 +01:00
Alexey Sokolov
44bbde35ee Revert "Fix #1147: show new server name when jumping" 2015-10-15 08:38:02 +01:00
Alexey Sokolov
e57f6460a1 Merge pull request #1149 from jreese/server-details
Fix #1147: show new server name when jumping
2015-10-15 08:33:58 +01:00
Alexey Sokolov
87a921d87a Merge pull request #1139 from Zarthus/expandstring-network
Expandstring network, alphabeticize expandstring list
2015-10-15 08:31:50 +01:00
John Reese
5f79f2d01f Fix #1147: show new server name when jumping
This updates the connect command in *status to retrieve the next server
object before triggering the jump, thereby allowing it to display the
next server's name rather than a generic message.
2015-10-12 16:27:01 -07:00
Jos Ahrens
2c8baa8193 ExpandString %network%, alphabeticize ExpandString list 2015-10-08 21:39:02 +02:00
Alexey Sokolov
0750e529c5 Don't print anything from signal handler.
Thread sanitizer doesn't like that.
2015-10-03 19:29:01 +01:00
Jos Ahrens
2031a82a77 Remove 'ok' from bootup
ZNC previously sent 'ok' on a new line every time a process went alright in CUtils::PrintStatus

No longer is this the case! ZNC now remains silent when everything is going well.
2015-09-25 13:11:33 +02:00
J-P Nurmi
3cb2834cc5 Fix STATUSMSG buffering 2015-09-21 15:41:20 +02:00
J-P Nurmi
c83a41ce89 CClient: message handlers 2015-09-20 23:22:03 +02:00
J-P Nurmi
4d3b47f2b1 Refactor CClient::ReadLine() to take advantage of CMessage::Type 2015-09-20 23:22:03 +02:00
J-P Nurmi
0c6215df9e CClient: use CModeMessage 2015-09-20 23:22:03 +02:00
J-P Nurmi
658db6bbe6 Make CMessage::ToString() use GetParams()
Avoids having the same loop in two places.

GetParams() was under consideration to be removed after the CMessage
porting work is done, but it's starting to look like it's here to stay.
There are cases, such as mode messages, where "get all params starting
from position N" is handy.
2015-09-20 23:22:03 +02:00
J-P Nurmi
ecb9b21055 Move message tags related code from CUtils to CMessage 2015-09-20 23:22:03 +02:00
J-P Nurmi
7d10ad2625 CBuffer: add CMessage-based API 2015-09-20 23:22:03 +02:00
J-P Nurmi
cbd860c2a9 Add CMessage::Equals()
Compares sender, command, and parameters. Not timestamp nor tags.
2015-09-20 23:22:02 +02:00
J-P Nurmi
dce6d4f0ea Make CClient::PutClient() handle multi-prefix 2015-09-20 23:22:02 +02:00
J-P Nurmi
f7802209ae Make CClient::PutClient() handle extended-join 2015-09-20 23:22:02 +02:00
J-P Nurmi
f4c22aff6c Incorporate CIRCSock::ForwardRaw353() into CClient::PutClient() 2015-09-20 23:22:02 +02:00
J-P Nurmi
69f1138052 CClient::PutClient(): handle away-notify and account-notify 2015-09-20 23:22:02 +02:00
J-P Nurmi
0f2a37707f CIRCSock::OnNumericMessage(): replace Token(n) with GetParam(m)
CMessage has already done the work to split the line to params.
2015-09-20 23:22:01 +02:00
J-P Nurmi
cb84ecac9c Port CIRCSock::ParseISupport() to use CMessage 2015-09-20 23:22:01 +02:00
J-P Nurmi
6ad7cdb4a2 Resolve #818: "Got ZNC?" is a little weird real name 2015-09-20 23:22:01 +02:00
Alexey Sokolov
41f1e317c4 Merge pull request #1080 from RealRancor/add_httponly_flag
Set HttpOnly for session cookie
2015-09-19 13:55:19 +01:00
J-P Nurmi
cde9053205 Fix memset() in CUtils::ParseServerTime() 2015-09-18 09:26:58 +02:00
J-P Nurmi
683379df7d CUtils::ParseServerTime(): fix handling of invalid timestamps 2015-09-18 01:16:01 +02:00
J-P Nurmi
6d42675a3a CMessage::SetParams(): forget the colon
1a3e9ec made CMessage try to retain the colon if the original message
contained one. We should not, however, remember that when the params
are replaced entirely. Consider for example an extended-join message
that is made suitable for a client that doesn't have extended-join
capability:

    CMessage msg(":nick!ident@host JOIN #chan account :real name");
    msg.SetParams({msg.GetParam(0)});
    msg.ToString(); // ":nick!ident@host JOIN :#chan"
2015-09-13 02:17:57 +02:00
RealRancor
41f83e8de4 Set HttpOnly for session cookie 2015-09-11 16:51:07 +02:00
J-P Nurmi
7f03484899 CClient: add ATTACH command
The main benefit is that (unlike JOIN) ATTACH allows wildcards.
It's also nicely symmetric with DETACH.
2015-09-10 01:12:19 +02:00
J-P Nurmi
832430659f CClient: share the chan detaching code 2015-09-10 01:12:19 +02:00
J-P Nurmi
7916efa997 CClient: share the chan matching code 2015-09-10 01:12:19 +02:00
J-P Nurmi
1a3e9ecb86 Resolve #1045: Make CMessage retain the colon
If the colon was there when parsed, stick it back even if it would be
technically unnecessary.
2015-09-10 00:21:04 +02:00
J-P Nurmi
ba76e041b9 Add OnNumericMessage() module hook (close #1069) 2015-09-07 16:41:15 +02:00
J-P Nurmi
c7cb7fca3f Cleanup CIRCSock::ReadLine() 2015-09-07 00:00:28 +02:00
J-P Nurmi
dae21026fa CIRCSock::OnErrorMessage() handler 2015-09-07 00:00:28 +02:00
J-P Nurmi
41b71e3a40 CIRCSock::OnPing/PongMessage() handlers 2015-09-07 00:00:28 +02:00
J-P Nurmi
da06aacd4d CIRCSock::OnNumericMessage() handler 2015-09-07 00:00:28 +02:00
J-P Nurmi
0446aaa929 CIRCSock::OnModeMessage() handler 2015-09-07 00:00:27 +02:00
J-P Nurmi
b8dbdb0a4b CIRCSock::OnWallopsMessage() handler 2015-09-07 00:00:27 +02:00
J-P Nurmi
1346718308 CIRCSock::OnCapabilityMessage() handler 2015-09-07 00:00:27 +02:00
J-P Nurmi
d3f42cabeb CIRCSock::OnInviteMessage() handler 2015-09-07 00:00:27 +02:00
J-P Nurmi
05fbb52173 CIRCSock::OnAccountMessage() handler 2015-09-07 00:00:27 +02:00
J-P Nurmi
d556a29218 CIRCSock::OnAwayMessage() handler 2015-09-07 00:00:27 +02:00
J-P Nurmi
d53a2d1f24 CIRCSock::OnTextMessage() handler 2015-09-07 00:00:27 +02:00
J-P Nurmi
236bd7249f CIRCSock::OnActionMessage() handler 2015-09-07 00:00:26 +02:00
J-P Nurmi
74be5522d1 CIRCSock::OnCTCPMessage() handler 2015-09-07 00:00:26 +02:00
J-P Nurmi
30bb92fec3 CIRCSock::OnNoticeMessage() handler 2015-09-07 00:00:26 +02:00
J-P Nurmi
b459cdf85b CIRCSock::OnTopicMessage() handler 2015-09-07 00:00:26 +02:00