Batch request capabilities during negotiation
authorShane Synan <digitalcircuit36939@gmail.com>
Tue, 6 Sep 2016 08:56:52 +0000 (03:56 -0500)
committerManuel Nickschas <sputnick@quassel-irc.org>
Wed, 7 Sep 2016 19:29:40 +0000 (21:29 +0200)
commit5013eef8eb17221e8f5866977f02e970e30ec0ac
tree75f81745bfbd889d8219bead27b10fd6049247ac
parenteebabe9514044150c2dbff477a8752c1649054bc
Batch request capabilities during negotiation

Split apart capability queue into individual and bundled groups.
Request capabilities one-at-a-time in the individual queue, and as
many as will fit within length limits in the bundled queue.  Use a
length limit of 100 characters to follow minimum number of characters
that IRC servers must return in CAP NAK replies, also meaning CAP NAK
replies will contain the full list of denied capabilities.

Individually request SASL and other capabilities requiring
configuration to avoid conflicts with requesting new capabilities
while still setting up the current capability.

Retry bundled capability requests individually when failed.  This
prevents one failing capability from blocking others.  Unfortunately
there's no way to avoid blindly re-requesting as CAP NAK does not
specify which capability failed.

Show a warning when retrying capabilities individually to explain the
added delay in logging in and to ease troubleshooting.

Fix documentation regarding capability handling.

Resolves GH-221.
src/core/corenetwork.cpp
src/core/corenetwork.h
src/core/coresessioneventprocessor.cpp