aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--src/pgm.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/pgm.cpp b/src/pgm.cpp
index ff6c2f9..5e30d32 100644
--- a/src/pgm.cpp
+++ b/src/pgm.cpp
@@ -70,7 +70,7 @@ typedef uint32_t pgm_fd_mask_t;
70 70
71static __thread char errnostr_buf[80]; 71static __thread char errnostr_buf[80];
72 72
73static inline pid_t gettid(void) 73static inline pid_t pgm_gettid(void)
74{ 74{
75 pid_t p = syscall(__NR_gettid); 75 pid_t p = syscall(__NR_gettid);
76 return p; 76 return p;
@@ -3186,7 +3186,7 @@ int pgm_claim_node(node_t node, pid_t tid)
3186 goto out; 3186 goto out;
3187 } 3187 }
3188 3188
3189 n->owner = (tid == 0) ? gettid() : tid; 3189 n->owner = (tid == 0) ? pgm_gettid() : tid;
3190 } 3190 }
3191 pthread_mutex_unlock(&g->lock); 3191 pthread_mutex_unlock(&g->lock);
3192 3192
@@ -3218,7 +3218,7 @@ int pgm_claim_any_node(graph_t graph, node_t* node, pid_t tid)
3218 { 3218 {
3219 node_id = i; 3219 node_id = i;
3220 n = &g->nodes[i]; 3220 n = &g->nodes[i];
3221 n->owner = (tid == 0) ? gettid() : tid; 3221 n->owner = (tid == 0) ? pgm_gettid() : tid;
3222 break; 3222 break;
3223 } 3223 }
3224 } 3224 }
@@ -3254,7 +3254,7 @@ int pgm_release_node(node_t node, pid_t tid)
3254 3254
3255 if(tid == 0) 3255 if(tid == 0)
3256 { 3256 {
3257 tid = gettid(); 3257 tid = pgm_gettid();
3258 } 3258 }
3259 3259
3260 pthread_mutex_lock(&g->lock); 3260 pthread_mutex_lock(&g->lock);