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:
nisheeth%netscape.com 2000-04-13 04:13:41 +00:00
Родитель f305fe2963
Коммит 6bc7ddfccb
4 изменённых файлов: 2 добавлений и 28 удалений

Просмотреть файл

@ -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;
}