weaved: Fix OnProtocolHandlerConnected notification

Web server may have multiple protocol handlers on many ports, but
weave cares only for the default ones on port 80 and 443. When both
handlers are available, we invoke |server_available_callback_| callback.

The current code had a problem that https port was used in condition
twice and also when another protocol handler is connected after the
default http/https ones, the callback will be invoked multiple times.

BUG:27655609
Change-Id: I0982bb37d29974bf7de127405c2aca0190a48a3d
1 file changed