| 177 | ); |
| 178 | } |
| 179 | void VpnPlugin::StopLeaf() { |
| 180 | m_backTransport = nullptr; |
| 181 | |
| 182 | auto leafHandle = m_leaf; |
| 183 | if (leafHandle != nullptr) { |
| 184 | uwp_stop_leaf(leafHandle); |
| 185 | m_leaf = nullptr; |
| 186 | } |
| 187 | |
| 188 | auto netStackHandle = m_netStackHandle; |
| 189 | if (netStackHandle != nullptr) { |
| 190 | const auto context = netstack_release(netStackHandle); |
| 191 | m_netStackHandle = nullptr; |
| 192 | // Release context, which is an ABI of IOutputStream |
| 193 | IInspectable obj{}; |
| 194 | winrt::attach_abi(obj, context); |
| 195 | m_netStackHandle = nullptr; |
| 196 | } |
| 197 | } |
| 198 | void VpnPlugin::Disconnect(VpnChannel const& channel) |
| 199 | { |
| 200 | try { |
nothing calls this directly
no outgoing calls
no test coverage detected