aboutsummaryrefslogtreecommitdiff
path: root/lib/Support/Unix/Signals.inc
diff options
context:
space:
mode:
Diffstat (limited to 'lib/Support/Unix/Signals.inc')
-rw-r--r--lib/Support/Unix/Signals.inc6
1 files changed, 5 insertions, 1 deletions
diff --git a/lib/Support/Unix/Signals.inc b/lib/Support/Unix/Signals.inc
index 87162d6951..af9e739e6d 100644
--- a/lib/Support/Unix/Signals.inc
+++ b/lib/Support/Unix/Signals.inc
@@ -295,7 +295,11 @@ void llvm::sys::PrintStackTrace(FILE *FD) {
else fputs(d, FD);
free(d);
- fprintf(FD, " + %tu",(char*)StackTrace[i]-(char*)dlinfo.dli_saddr);
+ // FIXME: When we move to C++11, use %t length modifier. It's not in
+ // C++03 and causes gcc to issue warnings. Losing the upper 32 bits of
+ // the stack offset for a stack dump isn't likely to cause any problems.
+ fprintf(FD, " + %u",(unsigned)((char*)StackTrace[i]-
+ (char*)dlinfo.dli_saddr));
}
fputc('\n', FD);
}