summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJoerg Bornemann <joerg.bornemann@digia.com>2013-07-24 09:11:24 +0200
committerChristian Kandeler <christian.kandeler@digia.com>2013-07-24 10:23:10 +0200
commit386d329e5df8a644a8bcfa2eed193a0dbad4f5bd (patch)
tree213e454cd3323e8ed5f5764e0fef6becebec0810
parent173762952caf40f9e6c852dbd63a4e68138b00c1 (diff)
downloadqbs-386d329e5df8a644a8bcfa2eed193a0dbad4f5bd.tar.gz
make the line number in JS command errors less wrong
Change-Id: Ib41691daf497d6587cb1d37b8a81728de4043e39 Reviewed-by: Christian Kandeler <christian.kandeler@digia.com>
-rw-r--r--src/lib/buildgraph/jscommandexecutor.cpp6
1 files changed, 2 insertions, 4 deletions
diff --git a/src/lib/buildgraph/jscommandexecutor.cpp b/src/lib/buildgraph/jscommandexecutor.cpp
index a7f104aea..c857a3746 100644
--- a/src/lib/buildgraph/jscommandexecutor.cpp
+++ b/src/lib/buildgraph/jscommandexecutor.cpp
@@ -98,10 +98,8 @@ public slots:
if (scriptEngine->hasUncaughtException()) {
m_result.success = false;
m_result.errorMessage = scriptEngine->uncaughtException().toString();
- const CodeLocation &origLocation = cmd->codeLocation();
- m_result.errorLocation = CodeLocation(origLocation.fileName(),
- origLocation.line() + scriptEngine->uncaughtExceptionLineNumber(),
- origLocation.column());
+ // ### We don't know the line number of the command's sourceCode property assignment.
+ m_result.errorLocation = cmd->codeLocation();
}
emit finished();
}