()
| 212 | } |
| 213 | |
| 214 | private respawnNow(): void { |
| 215 | this.respawnTimer = null; |
| 216 | if (this.disposed) return; |
| 217 | try { |
| 218 | this.term = this.spawnChild(); |
| 219 | this.log.info('session.respawned', { pid: this.term.pid }); |
| 220 | this.sendControl({ type: 'lifecycle', kind: 'child-respawn', pid: this.term.pid }); |
| 221 | } catch (err) { |
| 222 | this.log.error('session.respawn_failed', { err }); |
| 223 | this.sendControl({ type: 'exit', code: -1, signal: null }); |
| 224 | this.dispose('respawn failed'); |
| 225 | } |
| 226 | } |
| 227 | |
| 228 | get pid(): number { |
| 229 | return this.term.pid; |
no test coverage detected