Closed Bug 71223 Opened 23 years ago Closed 23 years ago

ASSERT in WalletService.cpp interfears with full-page plugins

Categories

(Core Graveyard :: Plug-ins, defect)

PowerPC
Mac System 9.x
defect
Not set
normal

Tracking

(Not tracked)

VERIFIED WONTFIX
mozilla0.9

People

(Reporter: peterlubczynski-bugs, Assigned: peterlubczynski-bugs)

Details

Attachments

(2 files)

This ASSERT:

ENSURE_TRUE(docviewer) failed in nsWalletService.cpp line 279

comes up whenever a full-page plugin starts. Full-page plugins don't have a 
docviewer.
r=morse via e-mail

Marc or Chris can you super review?
Status: NEW → ASSIGNED
Confirming the r=morse
Marking this bug INVALID. 

ENSURE_TRUE returns if it failed unlike ASSERT and without this return, there 
are problems (crashes) down the line. If there is no docViewer, we must return. 
Since the ENSURE_TRUE is annoying but does return, might as well leave it there 
unless you want me to change that Steve?
Status: ASSIGNED → RESOLVED
Closed: 23 years ago
Resolution: --- → INVALID
It's fine with me if you want to leave it as is.  But if you find it annoying, 
it's also fine with me for you to change it to an explicit test for the 
docviewer and do a (silent) return if it is not found.
If it is really Ok not to have a docViewer, and it is not an error, then you
should remove the NS_ENSURE and just do a normal check/return. NS_ENSURE is
suppossed to be noisy when the condition is false, just like an assert, I believe.

I recommend changing
  NS_ENSURE(docViewer,"...")
to
  if(!docViewer) return NS_OK

and then make sure that the non-error return is handled correctly. After all, it
is not an error here, right?

Question: why is wallet service even involved in  the full-page plugin display?
The reason wallet (i.e., password manager and form manager) are involved here is 
because of the OnEndDocumentLoad handler.  Password manager needs to fill in the 
password field when a document finishes loading.  I guess that handler gets 
called when plugins finish loading as well, which is why the code got invoked.
Reopening. I will fix this.
Status: RESOLVED → REOPENED
Resolution: INVALID → ---
Target Milestone: --- → mozilla0.8.1
Making Marc's recomendation. Seeking reviews from module owner and super 
reviewer?
Keywords: patch
Whiteboard: [seeking review]
sr=attinasi
Target Milestone: mozilla0.8.1 → mozilla0.9
I'm marking this WONTFIX (again) because patthing WalletSerice.cpp in this way 
still effects my work in full-page plugins. I will re-open if I find a problem 
later.
Status: REOPENED → RESOLVED
Closed: 23 years ago23 years ago
Resolution: --- → WONTFIX
v
Status: RESOLVED → VERIFIED
Hardware: PC → Macintosh
Whiteboard: [seeking review]
Product: Core → Core Graveyard
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: