StaticAnalyzer: Fix abuse of StringRef in r152962.

llvm-svn: 152982
This commit is contained in:
NAKAMURA Takumi 2012-03-17 13:06:05 +00:00
parent f3f6650f8f
commit 3ec7c4574f
2 changed files with 2 additions and 2 deletions

View File

@ -443,7 +443,7 @@ public:
/// Produce the hint for the given node. The node contains
/// information about the call for which the diagnostic can be generated.
StringRef getCallStackMessage(const ExplodedNode *N) {
std::string getCallStackMessage(const ExplodedNode *N) {
if (CallStackHint)
return CallStackHint->getMessage(N);
return "";

View File

@ -395,7 +395,7 @@ static void updateStackPiecesWithMessage(PathDiagnosticPiece *P,
E = CallStack.end(); I != E; ++I) {
PathDiagnosticCallPiece *CP = I->first;
const ExplodedNode *N = I->second;
StringRef stackMsg = ep->getCallStackMessage(N);
std::string stackMsg = ep->getCallStackMessage(N);
// The last message on the path to final bug is the most important
// one. Since we traverse the path backwards, do not add the message