| 8327 | } |
| 8328 | |
| 8329 | TSReturnCode |
| 8330 | TSVConnProtocolEnable(TSVConn connp, const char *protocol_name) |
| 8331 | { |
| 8332 | TSReturnCode retval = TS_ERROR; |
| 8333 | int protocol_idx = globalSessionProtocolNameRegistry.toIndexConst(std::string_view{protocol_name}); |
| 8334 | auto net_vc = reinterpret_cast<UnixNetVConnection *>(connp); |
| 8335 | if (auto alpn = net_vc->get_service<ALPNSupport>(); alpn) { |
| 8336 | alpn->enableProtocol(protocol_idx); |
| 8337 | retval = TS_SUCCESS; |
| 8338 | } |
| 8339 | return retval; |
| 8340 | } |
| 8341 | |
| 8342 | TSReturnCode |
| 8343 | TSVConnProtocolDisable(TSVConn connp, const char *protocol_name) |
nothing calls this directly
no test coverage detected