You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@qpid.apache.org by GitBox <gi...@apache.org> on 2020/06/15 14:19:15 UTC

[GitHub] [qpid-dispatch] ted-ross commented on a change in pull request #760: DISPATCH-1679: Add sys_thread_self()

ted-ross commented on a change in pull request #760:
URL: https://github.com/apache/qpid-dispatch/pull/760#discussion_r440209978



##########
File path: src/posix/threading.c
##########
@@ -150,19 +150,38 @@ void sys_rwlock_unlock(sys_rwlock_t *lock)
 
 struct sys_thread_t {
     pthread_t thread;
+    void *(*f)(void *);
+    void *arg;
 };
 
+static __thread sys_thread_t *_self;
+
+
+// bootstrap _self before calling main thread function
+//
+static void *_thread_init(void *arg)
+{
+    _self = (sys_thread_t *)arg;

Review comment:
       Style:
   `(sys_thread_t*) arg;`




----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@qpid.apache.org
For additional commands, e-mail: dev-help@qpid.apache.org