|
Hello,
I am looking for a way how to obtain an identifier of a calling
thread/process... I have to distinguish between different threads
in the code and thus missing some equivalent to UNIX-like
thr_self() / pthread_self() / getpid()
any ideas/tricks how to easily implement this in legOS?
Pavel.
|
|
Message has 1 Reply: | | Re: getpid?
|
| (...) AFAIK there aren't any built-in mechanisms. However, when a thread is launched, the launching process does get its PID as a return value from execi(). I'm thinking you could pass in a pointer to some storage in the argv, and then update that (...) (24 years ago, 14-Dec-00, to lugnet.robotics.rcx.legos)
|
7 Messages in This Thread:
- Entire Thread on One Page:
- Nested:
All | Brief | Compact | Dots
Linear:
All | Brief | Compact
|
|
|
|