[cfe-commits] r105759 - /cfe/trunk/lib/Frontend/CompilerInvocation.cpp
Daniel Dunbar
daniel at zuster.org
Wed Jun 9 15:30:54 PDT 2010
Author: ddunbar
Date: Wed Jun 9 17:30:54 2010
New Revision: 105759
URL: http://llvm.org/viewvc/llvm-project?rev=105759&view=rev
Log:
Frontend: Fix crashes on error paths.
Modified:
cfe/trunk/lib/Frontend/CompilerInvocation.cpp
Modified: cfe/trunk/lib/Frontend/CompilerInvocation.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Frontend/CompilerInvocation.cpp?rev=105759&r1=105758&r2=105759&view=diff
==============================================================================
--- cfe/trunk/lib/Frontend/CompilerInvocation.cpp (original)
+++ cfe/trunk/lib/Frontend/CompilerInvocation.cpp Wed Jun 9 17:30:54 2010
@@ -727,7 +727,7 @@
// FIXME: Error handling.
if (Value == NumStores)
Diags.Report(diag::err_drv_invalid_value)
- << Args.getLastArg(OPT_O)->getAsString(Args) << Name;
+ << A->getAsString(Args) << Name;
else
Opts.AnalysisStoreOpt = Value;
}
@@ -742,7 +742,7 @@
// FIXME: Error handling.
if (Value == NumConstraints)
Diags.Report(diag::err_drv_invalid_value)
- << Args.getLastArg(OPT_O)->getAsString(Args) << Name;
+ << A->getAsString(Args) << Name;
else
Opts.AnalysisConstraintsOpt = Value;
}
@@ -757,7 +757,7 @@
// FIXME: Error handling.
if (Value == NUM_ANALYSIS_DIAG_CLIENTS)
Diags.Report(diag::err_drv_invalid_value)
- << Args.getLastArg(OPT_O)->getAsString(Args) << Name;
+ << A->getAsString(Args) << Name;
else
Opts.AnalysisDiagOpt = Value;
}
More information about the cfe-commits
mailing list