diff options
author | Johnny Willemsen <jwillemsen@remedy.nl> | 2021-01-07 09:32:19 +0100 |
---|---|---|
committer | Johnny Willemsen <jwillemsen@remedy.nl> | 2021-01-07 09:32:19 +0100 |
commit | 8c07da5c4316895917a33dbaed2171ed7ad00448 (patch) | |
tree | 12d3e0bffd0a4f71e9b585294aab43b3aba767bc /ACE | |
parent | 24eb6e59c4c172fe74031590c59401b93f76647b (diff) | |
download | ATCD-8c07da5c4316895917a33dbaed2171ed7ad00448.tar.gz |
Move thr_gettid to inline
* ACE/ace/OS_NS_Thread.cpp:
* ACE/ace/OS_NS_Thread.h:
* ACE/ace/OS_NS_Thread.inl:
Diffstat (limited to 'ACE')
-rw-r--r-- | ACE/ace/OS_NS_Thread.cpp | 10 | ||||
-rw-r--r-- | ACE/ace/OS_NS_Thread.h | 2 | ||||
-rw-r--r-- | ACE/ace/OS_NS_Thread.inl | 10 |
3 files changed, 11 insertions, 11 deletions
diff --git a/ACE/ace/OS_NS_Thread.cpp b/ACE/ace/OS_NS_Thread.cpp index 4c94dd13120..93b431881c5 100644 --- a/ACE/ace/OS_NS_Thread.cpp +++ b/ACE/ace/OS_NS_Thread.cpp @@ -4840,16 +4840,6 @@ ACE_OS::unique_name (const void *object, } #endif -pid_t -ACE_OS::thr_gettid () -{ -#ifdef ACE_HAS_GETTID - return syscall (SYS_gettid); -#else - ACE_NOTSUP_RETURN (-1); -#endif -} - ACE_END_VERSIONED_NAMESPACE_DECL #if defined (ACE_VXWORKS) && !defined (__RTP__) diff --git a/ACE/ace/OS_NS_Thread.h b/ACE/ace/OS_NS_Thread.h index 313c05317df..9419f1d0812 100644 --- a/ACE/ace/OS_NS_Thread.h +++ b/ACE/ace/OS_NS_Thread.h @@ -1767,7 +1767,7 @@ namespace ACE_OS { * For older Linux (pre 2.4.11) and other systems that don't have gettid(), * this uses ACE_NOTSUP_RETURN (-1). */ - ACE_Export + ACE_NAMESPACE_INLINE_FUNCTION pid_t thr_gettid (); /** diff --git a/ACE/ace/OS_NS_Thread.inl b/ACE/ace/OS_NS_Thread.inl index 4b34fdeea11..7ab6d5894f1 100644 --- a/ACE/ace/OS_NS_Thread.inl +++ b/ACE/ace/OS_NS_Thread.inl @@ -3179,6 +3179,16 @@ ACE_OS::thr_gettid (char buffer[], size_t buffer_length) static_cast<int> (ACE_OS::thr_gettid ())); } +ACE_INLINE pid_t +ACE_OS::thr_gettid () +{ +#ifdef ACE_HAS_GETTID + return syscall (SYS_gettid); +#else + ACE_NOTSUP_RETURN (-1); +#endif +} + ACE_INLINE ACE_thread_t ACE_OS::thr_self () { |