Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(4636)

Unified Diff: base/stats_table.cc

Issue 18677: Use PlatformThreadId, not int when dealing with thread ids. (Closed)
Patch Set: Addressing comments Created 11 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « base/simple_thread.h ('k') | base/thread.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: base/stats_table.cc
diff --git a/base/stats_table.cc b/base/stats_table.cc
index 1f2545795f0a78dbf4e9aa622bec5d55e6186257..31570b50b96c4618f1f274af3d1b65f8cea765b6 100644
--- a/base/stats_table.cc
+++ b/base/stats_table.cc
@@ -126,7 +126,7 @@ class StatsTablePrivate {
return &thread_names_table_[
(slot_id-1) * (StatsTable::kMaxThreadNameLength)];
}
- int* thread_tid(int slot_id) const {
+ PlatformThreadId* thread_tid(int slot_id) const {
return &(thread_tid_table_[slot_id-1]);
}
int* thread_pid(int slot_id) const {
@@ -155,7 +155,7 @@ class StatsTablePrivate {
base::SharedMemory shared_memory_;
TableHeader* table_header_;
char* thread_names_table_;
- int* thread_tid_table_;
+ PlatformThreadId* thread_tid_table_;
int* thread_pid_table_;
char* counter_names_table_;
int* data_table_;
@@ -217,7 +217,7 @@ void StatsTablePrivate::ComputeMappedPointers(void* memory) {
max_threads() * StatsTable::kMaxThreadNameLength;
offset += AlignOffset(offset);
- thread_tid_table_ = reinterpret_cast<int*>(data + offset);
+ thread_tid_table_ = reinterpret_cast<PlatformThreadId*>(data + offset);
offset += sizeof(int) * max_threads();
offset += AlignOffset(offset);
« no previous file with comments | « base/simple_thread.h ('k') | base/thread.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698