getthreadname

Returns the name of the specified thread.

Library:LibC
Service:Library

Syntax

  #include <library.h> 
   
  int getthreadname (
     void    *threadid,
     char    *name,
     size_t   maxlen);
  

Parameters

threadid

(IN) Points to the ID of a thread, obtained by calling getthreadid. If NULL, uses the ID of the thread of the calling process.

name

(IN/OUT) Points to the name for the thread.

maxlen

(IN) Specifies the length of the name buffer.

Return Values

If successful, returns 0; otherwise, returns EBADHNDL if you pass an invalid thread ID.

See Also