From 344f7e3759cad217b0c3f7ff849e906f5970f554 Mon Sep 17 00:00:00 2001 From: Ted Kremenek Date: Thu, 3 Apr 2008 17:55:57 +0000 Subject: [PATCH] Use logical line number for BUGLINE. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@49178 91177308-0d34-0410-b5e6-96231b3b80d8 --- Driver/HTMLDiagnostics.cpp | 12 +++++------- 1 file changed, 5 insertions(+), 7 deletions(-) diff --git a/Driver/HTMLDiagnostics.cpp b/Driver/HTMLDiagnostics.cpp index c29096d0f6..8c89e6270a 100644 --- a/Driver/HTMLDiagnostics.cpp +++ b/Driver/HTMLDiagnostics.cpp @@ -74,18 +74,17 @@ void HTMLDiagnostics::HandlePathDiagnostic(const PathDiagnostic& D) { if (D.empty()) return; - if (!D.back()->getLocation().isFileID()) - return; - // Create the HTML directory if it is missing. if (!createdDir) { createdDir = true; - Directory.createDirectoryOnDisk(true, NULL); + std::string ErrorMsg; + Directory.createDirectoryOnDisk(true, &ErrorMsg); if (!Directory.isDirectory()) { llvm::cerr << "warning: could not create directory '" - << FilePrefix.toString() << "'\n"; + << Directory.toString() << "'\n" + << "reason: " << ErrorMsg << '\n'; noDir = true; @@ -154,8 +153,7 @@ void HTMLDiagnostics::HandlePathDiagnostic(const PathDiagnostic& D) { { std::ostringstream os; - FullSourceLoc L = D.back()->getLocation(); - os << "\n\n"; R.InsertStrBefore(SourceLocation::getFileLoc(FileID, 0), os.str()); } -- 2.40.0