The epicsThreadResume command assumes that epicsThreadGetName() will return an empty string when given an invalid thread id. That seems to be a reasonable interpretation as long as the architecture can identify a valid tid, but that isn't how the various versions have been implemented:
* RTEMS just converts the tid to a string using for format "0x%lx".
* VxWorks copies whatever taskName() gives back.
* Posix and Win32 assume it must be valid and copy a string from the relevant member.
I agree with the idea of adding a validator, but implementing it everywhere might need work.
The epicsThreadResume command assumes that epicsThreadGetN ame() will return an empty string when given an invalid thread id. That seems to be a reasonable interpretation as long as the architecture can identify a valid tid, but that isn't how the various versions have been implemented:
* RTEMS just converts the tid to a string using for format "0x%lx".
* VxWorks copies whatever taskName() gives back.
* Posix and Win32 assume it must be valid and copy a string from the relevant member.
I agree with the idea of adding a validator, but implementing it everywhere might need work.
Definitely needs a test in epicsThreadTest .cpp.