Closed Bug 253787 Opened 20 years ago Closed 17 years ago

In <nsContextMenu.js>, "Warning: reference to undefined property docshell.document.charset" (and other warnings/errors)

Categories

(SeaMonkey :: General, defect)

defect
Not set
minor

Tracking

(Not tracked)

RESOLVED FIXED
seamonkey1.0alpha

People

(Reporter: sgautherie, Assigned: sgautherie)

References

()

Details

(Keywords: fixed1.7.6, regression)

Attachments

(1 file, 3 obsolete files)

[Mozilla/5.0 (Windows; U; Win98; en-US; rv:1.8a2) Gecko/20040714] (release) (W98SE)

{{
Warning: reference to undefined property docshell.document.charset
Source File: chrome://communicator/content/nsContextMenu.js
Line: 642
}}

When clicking on page context menu "Bookmark This Page";
Yet the bookmark is added as expected.
Product: Browser → Seamonkey
It won't get added correctly if the URL contains non-ascii characters.
In that case, the characterSet is used to correctly decode them.
However the name of the variable appears to have been mistyped in this case.
[Mozilla/5.0 (Windows; U; Win98; en-US; rv:1.8a5) Gecko/20041122] (release) (W98SE)

Line number changed:
{{
Warning: reference to undefined property docshell.document.charset
Source File: chrome://communicator/content/nsContextMenu.js
Line: 650
}}

Neil:
I try on plain ascii URLs.
I'll try s/charset/characterSet/g ... there are 2 lines.
[Mozilla/5.0 (Windows; U; Win98; en-US; rv:1.7.3) Gecko/20040910] (release) (W98SE)

Bug already there.
I tested line 652: no more warning, bookmark still added.
I don't know how to test line 663...

Could you test/(super-)review/check in this patch ? Thanks.
Assignee: general → gautheri
Status: NEW → ASSIGNED
Attachment #168820 - Flags: superreview?(neil.parkwaycc.co.uk)
Attachment #168820 - Flags: review?(neil.parkwaycc.co.uk)
Attachment #168820 - Attachment description: (Av1) <nsContextMenu.js> → (Av1) "xpfe/" <nsContextMenu.js>
Attachment #168820 - Flags: superreview?(neil.parkwaycc.co.uk)
Attachment #168820 - Flags: superreview+
Attachment #168820 - Flags: review?(neil.parkwaycc.co.uk)
Attachment #168820 - Flags: review+
Fix checked in.
Status: ASSIGNED → RESOLVED
Closed: 20 years ago
Resolution: --- → FIXED
Attachment #168820 - Flags: approval1.7.5?
Target Milestone: --- → mozilla1.8alpha6
Status: RESOLVED → REOPENED
Resolution: FIXED → ---
I don't use TB: Could you test/review/check in this patch ? Thanks.
Attachment #168907 - Flags: review?(mscott)
Status: REOPENED → ASSIGNED
Comment on attachment 168820 [details] [diff] [review]
(Av1) "xpfe/" <nsContextMenu.js>
[Checked in: Comment 5 and 10]

1.7.5 has shipped. Moving request to 1.7.6.
Attachment #168820 - Flags: approval1.7.5? → approval1.7.6?
Comment on attachment 168907 [details] [diff] [review]
(Bv1-TB) <nsContextMenu.js>
[Checked in: Comment 19]

No review from <mscott@mozilla.org> since "2004-12-16" :-(
Attachment #168907 - Attachment description: (Bv1) "mail/" <nsContextMenu.js> → (Bv1-TB) <nsContextMenu.js>
Attachment #168907 - Flags: review?(mscott) → review?(bryner)
Comment on attachment 168820 [details] [diff] [review]
(Av1) "xpfe/" <nsContextMenu.js>
[Checked in: Comment 5 and 10]

a=caillon for 1.7.6, but please land this quickly.
Attachment #168820 - Flags: approval1.7.6? → approval1.7.6+
Attachment #168820 - Attachment description: (Av1) "xpfe/" <nsContextMenu.js> → (Av1) "xpfe/" <nsContextMenu.js> [Checked in: Comment 5]
Keywords: fixed1.7.6
Comment on attachment 168820 [details] [diff] [review]
(Av1) "xpfe/" <nsContextMenu.js>
[Checked in: Comment 5 and 10]


Check in: { 2005-02-11 16:04	neil%parkwaycc.co.uk	mozilla/ xpfe/
communicator/ resources/ content/ nsContextMenu.js	 1.88.2.1	
MOZILLA_1_7_BRANCH }
Attachment #168820 - Attachment description: (Av1) "xpfe/" <nsContextMenu.js> [Checked in: Comment 5] → (Av1) "xpfe/" <nsContextMenu.js> [Checked in: Comment 5 and 10]
Attachment #168820 - Attachment is obsolete: true
Attachment #168907 - Flags: review?(bryner) → review+
Comment on attachment 168907 [details] [diff] [review]
(Bv1-TB) <nsContextMenu.js>
[Checked in: Comment 19]

approval-aviary1.0.2?: already fixed1.7.6...
Attachment #168907 - Flags: approval-aviary1.0.2?
[Mozilla Thunderbird, version 1.0+ (20050319)] (nightly) (W98SE)

Trunk error, not present in v1.0 branch !!?
{{
Error: redeclaration of const kMailToLength
Source File: chrome://communicator/content/nsContextMenu.js
Line: 13
}}
_when starting TB_.

<http://lxr.mozilla.org/mozilla/search?string=kMailToLength>
{{
kMailToLength
/mail/base/content/nsContextMenu.js, line 52 -- const kMailToLength = 7;
/mail/base/content/nsContextMenu.js, line 579 -- if ( qmark > kMailToLength )
/mail/base/content/nsContextMenu.js, line 580 -- addresses = url.substring(
kMailToLength, qmark );
/mail/base/content/nsContextMenu.js, line 582 -- addresses = url.substr(
kMailToLength );
}}
It would seem that this file is loaded more than 1 time at/from a given place...

helpwanted.
Keywords: helpwanted
Attachment #168907 - Flags: approval-aviary1.0.2? → approval-aviary1.0.2-
Too late for 1.0.2.  Furthermore, if you actually wanted to get this on a
branch, you would need to describe:
 * what real bug (not warning) it was fixing
 * what the risks are (e.g., is it triggering codepaths that weren't previously
exercised, or is it triggering codepaths that were exercised via a different UI
path)

That said, since you seem to nominate way too many patches for branch checkin
(and just make drivers do a lot of extra work for things that obviously don't
need to be on branches), we'd probably just ignore your nomination anyway.
(In reply to comment #13)
> Too late for 1.0.2.  Furthermore, if you actually wanted to get this on a
> branch, you would need to describe:
>  * what real bug (not warning) it was fixing

{{
 ------- Additional Comment #1 From neil@parkwaycc.co.uk  2004-12-05 15:53 PST 
[reply] -------

It won't get added correctly if the URL contains non-ascii characters.
In that case, the characterSet is used to correctly decode them.
}}

>  * what the risks are (e.g., is it triggering codepaths that weren't previously
> exercised, or is it triggering codepaths that were exercised via a different UI
> path)

Little risk: I guess codepath for charset handling will be triggered where it
was not (lacking the data).

> That said, since you seem to nominate way too many patches for branch checkin
> (and just make drivers do a lot of extra work for things that obviously don't
> need to be on branches), we'd probably just ignore your nomination anyway.

:-(
Another one:

[Mozilla/5.0 (Windows; U; Win98; en-US; rv:1.7.5) Gecko/20041217] (release) (W98SE)

No bug

[Mozilla/5.0 (Windows; U; Win98; en-US; rv:1.8b) Gecko/20050217] (release) (W98SE)
[Mozilla/5.0 (Windows; U; Win98; en-US; rv:1.8b2) Gecko/20050317] (nightly) (W98SE)

When right clicking on a text input, like those of a bugzilla bug page
{{
Warning: assignment to undeclared variable type
Source File: chrome://communicator/content/nsContextMenu.js
Line: 294
}}

"Incorrect"'!?) fix from bug 110471, then _leftover_ from bug 245661.
Depends on: 245661
Attachment #178080 - Flags: superreview?(neil.parkwaycc.co.uk)
Attachment #178080 - Flags: review?(mconnor)
Keywords: regression
Summary: In <nsContextMenu.js>, "Warning: reference to undefined property docshell.document.charset" → In <nsContextMenu.js>, "Warning: reference to undefined property docshell.document.charset" (and other warnings/errors)
Target Milestone: mozilla1.8alpha6 → mozilla1.8beta2
Attachment #178080 - Flags: superreview?(neil.parkwaycc.co.uk) → superreview+
Or from bug 196380 for the xpfe version.
Depends on: 196380
Whiteboard: [checkin-needed]
Target Milestone: mozilla1.8beta2 → ---
Target Milestone: --- → Seamonkey1.0alpha
Attachment #168907 - Flags: approval-aviary1.1a?
Attachment #168907 - Flags: approval-aviary1.1a? → approval-aviary1.1a-
Comment on attachment 168907 [details] [diff] [review]
(Bv1-TB) <nsContextMenu.js>
[Checked in: Comment 19]

'approval1.8a2=?':
Trivial JS code cleanup, lo w risk.
Attachment #168907 - Flags: approval-aviary1.1a2?
Attachment #168907 - Flags: approval-aviary1.1a2? → approval-aviary1.1a2+
Comment on attachment 168907 [details] [diff] [review]
(Bv1-TB) <nsContextMenu.js>
[Checked in: Comment 19]

checked in.
Attachment #168907 - Attachment description: (Bv1-TB) <nsContextMenu.js> → (Bv1-TB) <nsContextMenu.js> [Checked in: Comment 19]
Attachment #168907 - Attachment is obsolete: true
Attachment #178080 - Flags: review?(mconnor) → review?(mscott)
Whiteboard: [checkin-needed]
Attachment #178080 - Flags: review?(mscott) → review+
Cv1, unbitrotted to current trunk,
for checkin.
Comment on attachment 262762 [details] [diff] [review]
(Cv1a) <nsContextMenu.js> (undeclared |type|)
[Checkin: Comment 21]


Checkin: {
2007-04-27 05:26	bugzilla%standard8.demon.co.uk
}
Attachment #262762 - Attachment description: (Cv1a) <nsContextMenu.js> (undeclared |type|) → (Cv1a) <nsContextMenu.js> (undeclared |type|) [Checkin: Comment 21]
Attachment #178080 - Attachment is obsolete: true
[Mozilla Thunderbird, version 2.0.0.4pre (20070427)] (nightly) (W2Ksp4)
[Mozilla Thunderbird, version 3.0a1 (20070427)] (nightly) (W2Ksp4)

(In reply to comment #12)
> Error: redeclaration of const kMailToLength
> _when starting TB_.

Not getting this one anymore.


R.Fixed.
Status: ASSIGNED → RESOLVED
Closed: 20 years ago17 years ago
Keywords: helpwanted
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: