diff --git a/server/include/path.h b/server/include/path.h index 3533f7fc7..ac2155d7b 100644 --- a/server/include/path.h +++ b/server/include/path.h @@ -53,9 +53,9 @@ struct path unsigned long skipped; /** The thread id for this path */ - pthread_t tid; + pthread_t recv_tid; /** A second thread id for fixed rate sending thread */ - pthread_t tid2; + pthread_t sent_tid; /** A pointer to the libconfig object which instantiated this path */ config_setting_t *cfg; diff --git a/server/src/path.c b/server/src/path.c index 51e006268..36dc47980 100644 --- a/server/src/path.c +++ b/server/src/path.c @@ -132,19 +132,19 @@ int path_start(struct path *p) { /* At fixed rate mode, we start another thread for sending */ if (p->rate) - pthread_create(&p->tid2, NULL, &path_send, (void *) p); + pthread_create(&p->sent_tid, NULL, &path_send, (void *) p); - return pthread_create(&p->tid, NULL, &path_run, (void *) p); + return pthread_create(&p->recv_tid, NULL, &path_run, (void *) p); } int path_stop(struct path *p) { - pthread_cancel(p->tid); - pthread_join(p->tid, NULL); + pthread_cancel(p->recv_tid); + pthread_join(p->recv_tid, NULL); if (p->rate) { - pthread_cancel(p->tid2); - pthread_join(p->tid2, NULL); + pthread_cancel(p->sent_tid); + pthread_join(p->sent_tid, NULL); } return 0;