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.detach Leaves Files Open #47

Open
kriscory opened this issue Apr 4, 2019 · 2 comments
Open

process.detach Leaves Files Open #47

kriscory opened this issue Apr 4, 2019 · 2 comments

Comments

@kriscory
Copy link

kriscory commented Apr 4, 2019

When process.detach is called the file handle to /proc/pid/mem is left open.

@vstinner
Copy link
Owner

vstinner commented Apr 4, 2019

Can you come up with a fix? This project is basically unmaintained, you have to fix the bugs that you find :-)

@spoutn1k
Copy link
Collaborator

spoutn1k commented Aug 19, 2020

It seems I am unable to reproduce the issue.

The steps taken were:

  • Adding a 10m sleep at the end of strace.py;
  • Launching an instance of strace.py;
  • Listing the opened files of the sleeping process.

~> lsof -p 8238 | grep /proc returns no matches.

The confusion might come from the fact that the /proc/<pid>/mem file is closed in a detach wrapper, _notRunning in ptrace/debugger/subprocess.py:302.

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

3 participants