Closed Bug 11724 Opened 25 years ago Closed 25 years ago

A crash occurs upon starting a Seamonkey component when some .dtd entity items are translated using 8-bit characters

Categories

(Core :: Internationalization: Localization, defect, P1)

x86
Windows NT
defect

Tracking

()

VERIFIED FIXED

People

(Reporter: momoi, Assigned: tao)

References

Details

** Observed with 8/10/99 Win32 M9 build **

We need to decide how important ficing this is for M9.
This certainly makes it difficult to localize some .dtd files.

This bug has been split from Bug 10539 where I reported
on the lack of entity extractions into .dtd files. The crashing
bug is a separate problem.
A very similar bug was reported on the i18n mozilla newsgroup
about using 8-bit Latin1 characters in .dtd files.

Here are currently known files where the use of 8-bit characters
in some ENTITY definitions cause a crash.

1. chrome\messengercompose\locale\en-US\messengercompose.dtd

2. chrome\global\locale\en-US\tasksOverlay.dtd

file.

In file 1: using 8-bit character in "FileMenuLabel ENTITY" causes a crash
            starting up a Mail Composer window.
In file 2: Just about any ENTITY definitions except some Button labels
           cause a crash upong apprunner startup.

Talkback reports are available and both crashes are very similar.

Here's part of Talkback report on File 1 crash:

Incident ID: 12326371
------------------------------------------------------------------
Trigger Type:  Program Crash
Trigger Reason:  Access violation
Call Stack:    (Signature = MSVCRT.dll + 0x156b (0x7800156b) dc1efda3)
MSVCRT.dll + 0x156b (0x7800156b)
ConverterInputStream::Read
[d:\builds\seamonkey\mozilla\xpcom\io\nsUnicharInputStream.cpp, line 255]
nsExpatTokenizer::LoadStream
[d:\builds\seamonkey\mozilla\htmlparser\src\nsExpatTokenizer.cpp, line 565]
nsExpatTokenizer::HandleExternalEntityRef
[d:\builds\seamonkey\mozilla\htmlparser\src\nsExpatTokenizer.cpp, line 607]
doProlog [d:\builds\seamonkey\mozilla\expat\xmlparse\xmlparse.c, line 2279]
prologProcessor [d:\builds\seamonkey\mozilla\expat\xmlparse\xmlparse.c, line
2146]
prologInitProcessor  [d:\builds\seamonkey\mozilla\expat\xmlparse\xmlparse.c,
line 2135]
XML_Parse [d:\builds\seamonkey\mozilla\expat\xmlparse\xmlparse.c, line 868]
nsExpatTokenizer::ParseXMLBuffer
[d:\builds\seamonkey\mozilla\htmlparser\src\nsExpatTokenizer.cpp, line 288]
nsExpatTokenizer::ConsumeToken
[d:\builds\seamonkey\mozilla\htmlparser\src\nsExpatTokenizer.cpp, line 332]
nsParser::Tokenize  [d:\builds\seamonkey\mozilla\htmlparser\src\nsParser.cpp,
line 1265]
nsParser::ResumeParse [d:\builds\seamonkey\mozilla\htmlparser\src\nsParser.cpp,
line 886]
nsParser::OnDataAvailable
[d:\builds\seamonkey\mozilla\htmlparser\src\nsParser.cpp, line 1170]

------------------------------------------------------------------

Here's part of the dump for File 2 crash:

Incident ID: 12326084
------------------------------------------------------------------
Trigger Type:  Program Crash
Trigger Reason:  Access violation
Call Stack:    (Signature = ntdll.dll + 0x4bfb (0x77f64bfb) 09d81208)
ntdll.dll + 0x4bfb (0x77f64bfb)
MSVCRT.dll + 0x1488 (0x78001488)
doProlog [d:\builds\seamonkey\mozilla\expat\xmlparse\xmlparse.c, line 2279]
prologProcessor [d:\builds\seamonkey\mozilla\expat\xmlparse\xmlparse.c, line
2146]
prologInitProcessor [d:\builds\seamonkey\mozilla\expat\xmlparse\xmlparse.c, line
2135]
XML_Parse [d:\builds\seamonkey\mozilla\expat\xmlparse\xmlparse.c, line 868]
nsExpatTokenizer::ParseXMLBuffer
[d:\builds\seamonkey\mozilla\htmlparser\src\nsExpatTokenizer.cpp, line 288]
nsExpatTokenizer::ConsumeToken
[d:\builds\seamonkey\mozilla\htmlparser\src\nsExpatTokenizer.cpp, line 332]
nsParser::Tokenize [d:\builds\seamonkey\mozilla\htmlparser\src\nsParser.cpp,
line 1265]
nsParser::ResumeParse [d:\builds\seamonkey\mozilla\htmlparser\src\nsParser.cpp,
line 886]
nsParser::OnDataAvailable
[d:\builds\seamonkey\mozilla\htmlparser\src\nsParser.cpp, line 1170]
------------------------------------------------------------------
If you want to see the full reports, go to this page:

http://cyclone/reports/reporttemplate.cfm?style=1&reportID=1099

and choose the link for this bug number (11724).
Blocks: 11652
To reproduce this crash, here's one set of steps. This uses
only Latin 1 8-bit characters and can be done
using US-WinNT4.

1. Modify chrome\messengercompose\locale\en-US\messengercompose.dtd
   (I normally make a backup of the .dtd file, then make another copy
    for modification.)
2. Take the file you created for modification (e.g. modmessengercompose.dtd)
    and make the following change:

    <!ENTITY fileMenu.label "Fle"> --> <!ENTITY fileMenu.label "Fêle">

    You can just copy this line over the original.

3. Now turn this file into UTF-8 encoding by using the
   nconv utility which comes with the latest "extratest.exe".
   You will find it in the same directory as the apprunner.

   Here's the command line:

   nsconv -f iso-8859-1 -t utf-8 modmessengercompose.dtd > messengercompose.dtd

  This replaces the original file with the modified one in UTF-8.

4. Now start the apprunner, start Mail, and then clcik on the
   New Mail button. This will lead to a crash.

(You can take the same steps with with just about any entity
  definitions in tasksOverlay.dtd file.)
Severity: normal → critical
Priority: P3 → P1
Status: NEW → ASSIGNED
Target Milestone: M10
Accepting bug and setting milestone to M10...

Harish, this is the bug that I wanted you to help me out on.  I won't be able to
look at this because of the XML demo on Friday.  Thanks for your help.
Adding meself to the CC list as my translation depends on this bug
QA Contact: teruko → amasri
*** Bug 12034 has been marked as a duplicate of this bug. ***
In bug Bug 12034, navigator,dtd file was found to cause a
a similar crash. Most items under "File" menu including
itself causes a crash. Most others don't seem to.
Include Adnan in the CC list.
The same happens with all the Prefs.dtd files.
Blocks: 12394
Same happens with navigator.dtd on Mac, not surprisingly.
Blocks: 6414
Assignee: nisheeth → tao
Status: ASSIGNED → NEW
Re-assigning this bug to Tao as he is working on the patch to fix this.
Tao, could you please move this bug in the top part of your priorities ??
Status: NEW → RESOLVED
Closed: 25 years ago
Resolution: --- → FIXED
Fix checked in.
Menu in navigator.dtd has been verified fixed.
Verified fixed on Mac.  Build 1999083010.
Changed a couple of strings here and there to Unicode Japanese.
Status: RESOLVED → VERIFIED
I'm going to nark this verified fixed  for all platforms.
You need to log in before you can comment on or make changes to this bug.