mirror of
https://github.com/microsoft/vscode.git
synced 2026-04-26 03:29:00 +01:00
@@ -23,8 +23,8 @@ class ExtensionTunnel implements vscode.Tunnel {
|
||||
onDidDispose: Event<void> = this._onDispose.event;
|
||||
|
||||
constructor(
|
||||
public readonly remoteAddress: { port: number; host: string; },
|
||||
public readonly localAddress: string,
|
||||
public readonly remoteAddress: { port: number, host: string },
|
||||
public readonly localAddress: { port: number, host: string } | string,
|
||||
private readonly _dispose: () => void) { }
|
||||
|
||||
dispose(): void {
|
||||
@@ -52,6 +52,7 @@ export class ExtHostTunnelService extends Disposable implements IExtHostTunnelSe
|
||||
this.registerCandidateFinder();
|
||||
}
|
||||
}
|
||||
|
||||
async openTunnel(forward: TunnelOptions): Promise<vscode.Tunnel | undefined> {
|
||||
const tunnel = await this._proxy.$openTunnel(forward);
|
||||
if (tunnel) {
|
||||
@@ -91,6 +92,7 @@ export class ExtHostTunnelService extends Disposable implements IExtHostTunnelSe
|
||||
} else {
|
||||
this._forwardPortProvider = undefined;
|
||||
}
|
||||
await this._proxy.$tunnelServiceReady();
|
||||
return toDisposable(() => {
|
||||
this._forwardPortProvider = undefined;
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user