Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Process HANDLE leak on windows #513

Closed
xhcoding opened this issue Dec 9, 2021 · 1 comment
Closed

Process HANDLE leak on windows #513

xhcoding opened this issue Dec 9, 2021 · 1 comment

Comments

@xhcoding
Copy link

xhcoding commented Dec 9, 2021

Environment details

  • OS: Windows10
  • OS version: 21H1 19043
  • node-pty version: 0.10.1

Issue description

var os = require('os');
var pty = require('node-pty');

var shell = os.platform() === 'win32' ? 'powershell' : 'bash';


setInterval(() => {

  console.log("spawn new process");
  var ptyProcess = pty.spawn(shell, [], {
    name: 'xterm-color',
    cols: 80,
    rows: 30
  });

  ptyProcess.kill();


}, 5000);

After the above code runs for a few minutes :

16390417046148

@Tyriar
Copy link
Member

Tyriar commented Dec 16, 2021

Should be fixed in #510

@Tyriar Tyriar closed this as completed Dec 16, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants