mirror of
https://github.com/python/cpython.git
synced 2025-07-07 11:25:30 +00:00
gh-134546: ensure remote pdb script is readable (#134552)
This commit is contained in:
parent
47f1161d3a
commit
74a9c60f3e
2 changed files with 4 additions and 0 deletions
|
@ -75,6 +75,7 @@ import dis
|
|||
import code
|
||||
import glob
|
||||
import json
|
||||
import stat
|
||||
import token
|
||||
import types
|
||||
import atexit
|
||||
|
@ -3418,6 +3419,8 @@ def attach(pid, commands=()):
|
|||
)
|
||||
)
|
||||
connect_script.close()
|
||||
orig_mode = os.stat(connect_script.name).st_mode
|
||||
os.chmod(connect_script.name, orig_mode | stat.S_IROTH | stat.S_IRGRP)
|
||||
sys.remote_exec(pid, connect_script.name)
|
||||
|
||||
# TODO Add a timeout? Or don't bother since the user can ^C?
|
||||
|
|
|
@ -0,0 +1 @@
|
|||
Ensure :mod:`pdb` remote debugging script is readable by remote Python process.
|
Loading…
Add table
Add a link
Reference in a new issue