Skip to content

Commit e9ac75b

Browse files
Remove redundant check of pid_to_task result
1 parent 6dfc0f0 commit e9ac75b

File tree

1 file changed

+0
-3
lines changed

1 file changed

+0
-3
lines changed

Modules/_testexternalinspection.c

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -222,9 +222,6 @@ search_map_for_section(pid_t pid, const char* secname, const char* substr) {
222222

223223
mach_port_t proc_ref = pid_to_task(pid);
224224
if (proc_ref == 0) {
225-
if (!PyErr_Occurred()) {
226-
PyErr_SetString(PyExc_PermissionError, "Cannot get task for PID");
227-
}
228225
return 0;
229226
}
230227

0 commit comments

Comments
 (0)