cmVariableWatchCommand: Simplify error reporting.

This commit is contained in:
Stephen Kelly 2015-05-23 20:30:37 +02:00
parent 499ebb6564
commit eb7b6f6db4
1 changed files with 1 additions and 4 deletions

View File

@ -68,11 +68,8 @@ static void cmVariableWatchCommandVariableAccessed(
cmExecutionStatus status; cmExecutionStatus status;
if(!makefile->ExecuteCommand(newLFF,status)) if(!makefile->ExecuteCommand(newLFF,status))
{ {
arg.FilePath = "Unknown";
arg.Line = 0;
std::ostringstream error; std::ostringstream error;
error << "Error in cmake code at\n" error << "Error in cmake code at\nUnknown:0:\n"
<< arg.FilePath << ":" << arg.Line << ":\n"
<< "A command failed during the invocation of callback \"" << "A command failed during the invocation of callback \""
<< data->Command << "\"."; << data->Command << "\".";
cmSystemTools::Error(error.str().c_str()); cmSystemTools::Error(error.str().c_str());