kerryjiang / WebSocket4Net

A popular .NET WebSocket Client
752 stars 272 forks source link

Subprotocol mismatch should not happen if response protocol doesn't exist #126

Open skyline75489 opened 6 years ago

skyline75489 commented 6 years ago

The code here https://github.com/kerryjiang/WebSocket4Net/blob/c48541e366aef463597614793ab4cc81b2a56c5f/WebSocket4Net/Protocol/DraftHybi10Processor.cs#L290 will always return false if protocol doesn't exist. I think we need an extra check for whether protocol is string.Empty.