aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/core/lib/support/cpu_posix.cc
diff options
context:
space:
mode:
authorGravatar Nicolas "Pixel" Noble <pixel@nobis-crew.org>2017-11-13 09:40:18 +0100
committerGravatar Nicolas "Pixel" Noble <pixel@nobis-crew.org>2017-11-13 09:40:18 +0100
commitad5bec0ee9436e91684b6eed042837473ccbaea7 (patch)
treeb747480ae4cacc5ab808852b6ffa958006cbde2a /src/core/lib/support/cpu_posix.cc
parent78bf698ac905064c22c9ae94f9d5218dba6815ab (diff)
Formatting.
Diffstat (limited to 'src/core/lib/support/cpu_posix.cc')
-rw-r--r--src/core/lib/support/cpu_posix.cc10
1 files changed, 5 insertions, 5 deletions
diff --git a/src/core/lib/support/cpu_posix.cc b/src/core/lib/support/cpu_posix.cc
index 2be66ef54e..a9284d8047 100644
--- a/src/core/lib/support/cpu_posix.cc
+++ b/src/core/lib/support/cpu_posix.cc
@@ -54,8 +54,8 @@ unsigned gpr_cpu_current_cpu(void) {
most code that's using this is using it to shard across work queues though,
so here we use thread identity instead to achieve a similar though not
identical effect */
- static auto DeleteValue = [](void *value_ptr) {
- unsigned int *value = static_cast<unsigned int *>(value_ptr);
+ static auto DeleteValue = [](void* value_ptr) {
+ unsigned int* value = static_cast<unsigned int*>(value_ptr);
if (value) {
gpr_free(value);
}
@@ -67,10 +67,10 @@ unsigned gpr_cpu_current_cpu(void) {
// of thread identity explicitly so hashing works reliably.
static std::atomic<unsigned int> thread_counter(0);
- unsigned int *thread_id =
- static_cast<unsigned int *>(pthread_getspecific(thread_id_key));
+ unsigned int* thread_id =
+ static_cast<unsigned int*>(pthread_getspecific(thread_id_key));
if (thread_id == nullptr) {
- thread_id = static_cast<unsigned int *>(gpr_malloc(sizeof(unsigned int)));
+ thread_id = static_cast<unsigned int*>(gpr_malloc(sizeof(unsigned int)));
*thread_id = thread_counter++;
pthread_setspecific(thread_id_key, thread_id);
}