зеркало из https://github.com/mozilla/pjs.git
Fix for bug 13565. Removed code that dumps XML error messages to console because error messages now show up inside the browser window.
This commit is contained in:
Родитель
f305fe2963
Коммит
6bc7ddfccb
|
@ -235,7 +235,7 @@ void nsExpatTokenizer::GetLine(const char* aSourceBuffer, PRUint32 aLength,
|
|||
{
|
||||
/* Figure out the line inside aSourceBuffer that contains character specified by aOffset.
|
||||
Copy it into aLine. */
|
||||
NS_ASSERTION(aOffset > 0 && aOffset < aLength, "?");
|
||||
NS_ASSERTION(aOffset >= 0 && aOffset < aLength, "?");
|
||||
/* Assert that the byteIndex and the length of the buffer is even */
|
||||
NS_ASSERTION(aOffset % 2 == 0 && aLength % 2 == 0, "?");
|
||||
PRUnichar* start = (PRUnichar* ) &aSourceBuffer[aOffset]; /* Will try to find the start of the line */
|
||||
|
|
|
@ -692,19 +692,6 @@ nsresult CWellFormedDTD::HandleErrorToken(CToken* aToken) {
|
|||
const nsParserError* error = errTok->GetError();
|
||||
result=(mSink)? mSink->NotifyError(error):NS_OK;
|
||||
|
||||
// Output the error to the console
|
||||
if (error) {
|
||||
char* temp;
|
||||
cout << "XML Error in file '" << (temp = mFilename.ToNewCString()) << "', ";
|
||||
Recycle(temp);
|
||||
cout << "Line Number: " << error->lineNumber << ", ";
|
||||
cout << "Col Number: " << error->colNumber << ", ";
|
||||
cout << "Description: " << (temp = error->description.ToNewCString()) << "\n";
|
||||
Recycle(temp);
|
||||
cout << "Source Line: " << (temp = error->sourceLine.ToNewCString()) << "\n";
|
||||
Recycle(temp);
|
||||
}
|
||||
|
||||
return result;
|
||||
}
|
||||
|
||||
|
|
|
@ -235,7 +235,7 @@ void nsExpatTokenizer::GetLine(const char* aSourceBuffer, PRUint32 aLength,
|
|||
{
|
||||
/* Figure out the line inside aSourceBuffer that contains character specified by aOffset.
|
||||
Copy it into aLine. */
|
||||
NS_ASSERTION(aOffset > 0 && aOffset < aLength, "?");
|
||||
NS_ASSERTION(aOffset >= 0 && aOffset < aLength, "?");
|
||||
/* Assert that the byteIndex and the length of the buffer is even */
|
||||
NS_ASSERTION(aOffset % 2 == 0 && aLength % 2 == 0, "?");
|
||||
PRUnichar* start = (PRUnichar* ) &aSourceBuffer[aOffset]; /* Will try to find the start of the line */
|
||||
|
|
|
@ -692,19 +692,6 @@ nsresult CWellFormedDTD::HandleErrorToken(CToken* aToken) {
|
|||
const nsParserError* error = errTok->GetError();
|
||||
result=(mSink)? mSink->NotifyError(error):NS_OK;
|
||||
|
||||
// Output the error to the console
|
||||
if (error) {
|
||||
char* temp;
|
||||
cout << "XML Error in file '" << (temp = mFilename.ToNewCString()) << "', ";
|
||||
Recycle(temp);
|
||||
cout << "Line Number: " << error->lineNumber << ", ";
|
||||
cout << "Col Number: " << error->colNumber << ", ";
|
||||
cout << "Description: " << (temp = error->description.ToNewCString()) << "\n";
|
||||
Recycle(temp);
|
||||
cout << "Source Line: " << (temp = error->sourceLine.ToNewCString()) << "\n";
|
||||
Recycle(temp);
|
||||
}
|
||||
|
||||
return result;
|
||||
}
|
||||
|
||||
|
|
Загрузка…
Ссылка в новой задаче