зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1250520
- Handle reporting DebuggeeWouldRun when the script has no filename. (r=fitzgen)
This commit is contained in:
Родитель
40e28dfd6d
Коммит
d617ebbc91
|
@ -346,12 +346,13 @@ class MOZ_RAII js::EnterDebuggeeNoExecute
|
|||
fprintf(stdout, "Dumping stack for DebuggeeWouldRun:\n");
|
||||
DumpBacktrace(cx);
|
||||
}
|
||||
const char* filename = script->filename() ? script->filename() : "(none)";
|
||||
char linenoStr[15];
|
||||
JS_snprintf(linenoStr, sizeof(linenoStr), "%" PRIuSIZE, script->lineno());
|
||||
unsigned flags = warning ? JSREPORT_WARNING : JSREPORT_ERROR;
|
||||
return JS_ReportErrorFlagsAndNumber(cx, flags, GetErrorMessage, nullptr,
|
||||
JSMSG_DEBUGGEE_WOULD_RUN,
|
||||
script->filename(), linenoStr);
|
||||
filename, linenoStr);
|
||||
}
|
||||
}
|
||||
return true;
|
||||
|
|
Загрузка…
Ссылка в новой задаче