summaryrefslogtreecommitdiff
path: root/components
diff options
context:
space:
mode:
authorheyuanjie87 <[email protected]>2025-01-21 13:01:58 +0800
committerGitHub <[email protected]>2025-01-21 13:01:58 +0800
commited3222c2f8355ca55cd35640f4c417e7a31ad56a (patch)
tree9f5325194c1e124e96403606c80899a8e9cc74ed /components
parent45bb1ddac9757b12d23b96c7b92cc7c28302e761 (diff)
[lwp]修正无法通过文件名查找pid的问题 (#9935)
Diffstat (limited to 'components')
-rw-r--r--components/lwp/lwp_pid.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/components/lwp/lwp_pid.c b/components/lwp/lwp_pid.c
index e45554434d..34285598df 100644
--- a/components/lwp/lwp_pid.c
+++ b/components/lwp/lwp_pid.c
@@ -813,7 +813,7 @@ pid_t lwp_name2pid(const char *name)
if (lwp)
{
- process_name = strrchr(lwp->cmd, '/');
+ process_name = strrchr(lwp->exe_file, '/');
process_name = process_name? process_name + 1: lwp->cmd;
if (!rt_strncmp(name, process_name, RT_NAME_MAX))
{