Enable -Wold-style-cast warnings for linker

And fix old style casts.

Change-Id: I37e7a3e3fd852528ea76f02d967c7bd8cd5b06c9
This commit is contained in:
Dmitriy Ivanov
2015-01-22 16:04:25 -08:00
parent ae095a730d
commit 1649e7ee5b
5 changed files with 15 additions and 10 deletions

View File

@@ -151,7 +151,7 @@ static void log_signal_summary(int signum, const siginfo_t* info) {
}
char thread_name[MAX_TASK_NAME_LEN + 1]; // one more for termination
if (prctl(PR_GET_NAME, (unsigned long)thread_name, 0, 0, 0) != 0) {
if (prctl(PR_GET_NAME, reinterpret_cast<unsigned long>(thread_name), 0, 0, 0) != 0) {
strcpy(thread_name, "<name unknown>");
} else {
// short names are null terminated by prctl, but the man page