* @brief Get the process ID of the current lightweight process (LWP) * * @return pid_t Process ID of the current LWP */
| 1143 | * @return pid_t Process ID of the current LWP |
| 1144 | */ |
| 1145 | int lwp_getpid(void) |
| 1146 | { |
| 1147 | rt_lwp_t lwp = lwp_self(); |
| 1148 | return lwp ? lwp->pid : 1; |
| 1149 | /* return ((struct rt_lwp *)rt_thread_self()->lwp)->pid; */ |
| 1150 | } |
| 1151 | |
| 1152 | /** |
| 1153 | * @brief Update resource usage statistics from child to parent process |
no test coverage detected