about summary refs log tree commit diff
path: root/absl/synchronization
diff options
context:
space:
mode:
Diffstat (limited to 'absl/synchronization')
-rw-r--r--absl/synchronization/internal/thread_pool.h3
1 files changed, 2 insertions, 1 deletions
diff --git a/absl/synchronization/internal/thread_pool.h b/absl/synchronization/internal/thread_pool.h
index 846404277a03..c753a68dbe83 100644
--- a/absl/synchronization/internal/thread_pool.h
+++ b/absl/synchronization/internal/thread_pool.h
@@ -16,6 +16,7 @@
 #define ABSL_SYNCHRONIZATION_INTERNAL_THREAD_POOL_H_
 
 #include <cassert>
+#include <cstddef>
 #include <functional>
 #include <queue>
 #include <thread>  // NOLINT(build/c++11)
@@ -42,7 +43,7 @@ class ThreadPool {
   ~ThreadPool() {
     {
       absl::MutexLock l(&mu_);
-      for (int i = 0; i < threads_.size(); ++i) {
+      for (size_t i = 0; i < threads_.size(); i++) {
         queue_.push(nullptr);  // Shutdown signal.
       }
     }