tsan: explictly say when we fail to restore a stack trace

llvm-svn: 168423
This commit is contained in:
Dmitry Vyukov 2012-11-21 11:44:20 +00:00
parent 3a3488e4e1
commit aeed45cde0
1 changed files with 4 additions and 0 deletions

View File

@ -50,6 +50,10 @@ static void PrintHeader(ReportType typ) {
}
void PrintStack(const ReportStack *ent) {
if (ent == 0) {
Printf(" [failed to restore the stack]\n");
return;
}
for (int i = 0; ent; ent = ent->next, i++) {
Printf(" #%d %s %s:%d", i, ent->func, ent->file, ent->line);
if (ent->col)