I'm getting this assertion when I attempt to connect to the websocket

It appear to be due to this section of code --
|
static boost::wregex const s_pat(LR"(^wss?://([\w\.]+):(\d+)(.*)$)"); |
|
|
|
boost::wsmatch matches; |
|
if (!boost::regex_match(std::wstring(szServer), matches, s_pat)) { |
|
COUT(L"Failed to parse host & port. Correct example: ws://localhost:8080/"); |
|
return 0; |
|
} |
|
|
|
std::wstring path(boost::trim_copy(matches[3].str())); |
|
if (path.empty()) |
|
path = L"/"; |
@sehe I've tried fixing this on my own, but I've been unsuccessful. I would appreciate some guidance.
A few related questions --
- Should
boost::regex_match be changed to boost::regex_search?
- Is there a strong reason to not use
boost::urls instead of regex?
I'm getting this assertion when I attempt to connect to the websocket
It appear to be due to this section of code --
WebSocketAsio/library.cpp
Lines 328 to 338 in e90faa3
@sehe I've tried fixing this on my own, but I've been unsuccessful. I would appreciate some guidance.
A few related questions --
boost::regex_matchbe changed toboost::regex_search?boost::urlsinstead of regex?