rename AdcEndpointPrser to AdcEndpoint
fixes
This commit is contained in:
@@ -108,7 +108,7 @@ int main(int argc, char* argv[])
|
||||
"endpoints server will be listening for. For 'local' endpoint the '@' symbol at the beginning of the path "
|
||||
"means "
|
||||
"abstract namespace socket.",
|
||||
cxxopts::value<std::vector<std::string>>()->default_value("local://stream/ADC_ASIO_TEST_SERVER"));
|
||||
cxxopts::value<std::vector<std::string>>()->default_value("local://stream/@ADC_ASIO_TEST_SERVER"));
|
||||
|
||||
|
||||
options.positional_help("[endpoint0] [enpoint1] ... [endpointN]");
|
||||
@@ -144,13 +144,13 @@ int main(int argc, char* argv[])
|
||||
auto epnt = opt_result["endpoints"].as<std::vector<std::string>>();
|
||||
|
||||
for (auto& ep : epnt) {
|
||||
adc::AdcEndpointParser epn(ep);
|
||||
adc::AdcEndpoint epn(ep);
|
||||
if (epn.isValid()) {
|
||||
if (epn.isLocalSeqpacket() || epn.isLocalStream()) {
|
||||
if (epn.path()[0] == '@') { // replace '@' to '\0' (use of UNIX abstract namespace)
|
||||
auto it = std::ranges::find(ep, '@');
|
||||
*it = '\0';
|
||||
epn = adc::AdcEndpointParser(ep);
|
||||
epn = adc::AdcEndpoint(ep);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user