summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
author <shinichiro.hamaji@gmail.com>2008-11-04 07:08:11 +0000
committer <shinichiro.hamaji@gmail.com>2008-11-04 07:08:11 +0000
commit1ea4ad6ba1df3fdab43d7350795741ce27a5e9fd (patch)
tree0c0cae2f23da900d1ce2700d1b428326a72ba864 /src
parentd15fcf784c8e138138946700db019c66d4a55752 (diff)
downloadglog-1ea4ad6ba1df3fdab43d7350795741ce27a5e9fd.tar.gz
glog-1ea4ad6ba1df3fdab43d7350795741ce27a5e9fd.tar.bz2
glog-1ea4ad6ba1df3fdab43d7350795741ce27a5e9fd.zip
Use uintptr_t instead of int as the integer format of pthread_t.
git-svn-id: https://google-glog.googlecode.com/svn/trunk@14 eb4d4688-79bd-11dd-afb4-1d65580434c0
Diffstat (limited to 'src')
-rw-r--r--src/signalhandler.cc6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/signalhandler.cc b/src/signalhandler.cc
index c49abc6..8e30297 100644
--- a/src/signalhandler.cc
+++ b/src/signalhandler.cc
@@ -189,10 +189,10 @@ void DumpSignalInfo(int signal_number, siginfo_t *siginfo) {
formatter.AppendString(" (TID 0x");
// We assume pthread_t is an integral number or a pointer, rather
// than a complex struct. In some environments, pthread_self()
- // returns an int64 but in some other environments pthread_self()
+ // returns an uint64 but in some other environments pthread_self()
// returns a pointer. Hence we use C-style cast here, rather than
// reinterpret/static_cast, to support both types of environments.
- formatter.AppendUint64((int)pthread_self(), 16);
+ formatter.AppendUint64((uintptr_t)pthread_self(), 16);
formatter.AppendString(") ");
// Only linux has the PID of the signal sender in si_pid.
#ifdef OS_LINUX
@@ -240,7 +240,7 @@ void InvokeDefaultSignalHandler(int signal_number) {
// This variable is used for protecting FailureSignalHandler() from
// dumping stuff while another thread is doing it. Our policy is to let
-// the first thread dump stuff and let other threads to wait.
+// the first thread dump stuff and let other threads wait.
// See also comments in FailureSignalHandler().
static pthread_t* g_entered_thread_id_pointer = NULL;