Closed Bug 116174 Opened 23 years ago Closed 23 years ago

Crash switching thread pane to threaded view after select all

Categories

(SeaMonkey :: MailNews: Message Display, defect, P1)

x86
Windows 2000
defect

Tracking

(Not tracked)

VERIFIED FIXED
mozilla0.9.8

People

(Reporter: trudelle, Assigned: sspitzer)

Details

Attachments

(1 file, 2 obsolete files)

build 2001121608:

Connect to IMAP server
Open folder.
Click in thread pane
Select All
Click thread icon (to put in threaded view)
Crash, reproducible.
Peter, do you have a talkack id for this?  I tried this on the 12/18 build and I
didn't crash but I did hang.
Keywords: nsbeta1+
Priority: -- → P2
Target Milestone: --- → mozilla0.9.9
I submitted one, but it hasn't showed up yet.
I think I just reproduced this bad boy.

moving to 0.9.8, as it is a crasher.
Status: NEW → ASSIGNED
Priority: P2 → P1
Target Milestone: mozilla0.9.9 → mozilla0.9.8
we assert, then crash here:

NTDLL! 77f9f9df()
nsDebug::Assertion(const char * 0x015b1360, const char * 0x015b134c, const char 
* 0x015b1310, int 142) line 290 + 13 bytes
nsUInt32Array::GetAt(unsigned int 3452816845) line 142 + 37 bytes
nsMsgDBView::OfflineMsgSelected(unsigned int * 0x081c5260, int 321) line 4860 + 
22 bytes
nsMsgDBView::SelectionChanged(nsMsgDBView * const 0x070b2578) line 884 + 25 
bytes
XPTC_InvokeByIndex(nsISupports * 0x070b2578, unsigned int 24, unsigned int 0, 
nsXPTCVariant * 0x0012ac40) line 106
XPCWrappedNative::CallMethod(XPCCallContext & {...}, XPCWrappedNative::CallMode 
CALL_METHOD) line 2009 + 42 bytes
XPC_WN_CallMethod(JSContext * 0x017b8430, JSObject * 0x05302690, unsigned int 
0, long * 0x058ae1fc, long * 0x0012af14) line 1266 + 14 bytes
js_Invoke(JSContext * 0x017b8430, unsigned int 0, unsigned int 0) line 832 + 23 
bytes
js_Interpret(JSContext * 0x017b8430, long * 0x0012bd04) line 2798 + 15 bytes
js_Invoke(JSContext * 0x017b8430, unsigned int 1, unsigned int 2) line 849 + 13 
bytes
js_InternalInvoke(JSContext * 0x017b8430, JSObject * 0x05302138, long 86666152, 
unsigned int 0, unsigned int 1, long * 0x0012bf74, long * 0x0012be2c) line 924 
+ 20 bytes
JS_CallFunctionValue(JSContext * 0x017b8430, JSObject * 0x05302138, long 
86666152, unsigned int 1, long * 0x0012bf74, long * 0x0012be2c) line 3405 + 31 
bytes
nsJSContext::CallEventHandler(nsJSContext * const 0x017be120, void * 
0x05302138, void * 0x052a6ba8, unsigned int 1, void * 0x0012bf74, int * 
0x0012bf78, int 0) line 1011 + 33 bytes
nsJSEventListener::HandleEvent(nsJSEventListener * const 0x063d2eb0, 
nsIDOMEvent * 0x082337d8) line 180 + 77 bytes
nsEventListenerManager::HandleEventSubType(nsListenerStruct * 0x063d2e10, 
nsIDOMEvent * 0x082337d8, nsIDOMEventTarget * 0x055e2b18, unsigned int 8, 
unsigned int 7) line 1205 + 20 bytes
nsEventListenerManager::HandleEvent(nsEventListenerManager * const 0x063d2f00, 
nsIPresContext * 0x017d25f0, nsEvent * 0x0012c9c4, nsIDOMEvent * * 0x0012c954, 
nsIDOMEventTarget * 0x055e2b18, unsigned int 7, nsEventStatus * 0x0012c9ec) 
line 1806 + 36 bytes
nsXULElement::HandleDOMEvent(nsXULElement * const 0x055e2b10, nsIPresContext * 
0x017d25f0, nsEvent * 0x0012c9c4, nsIDOMEvent * * 0x0012c954, unsigned int 1, 
nsEventStatus * 0x0012c9ec) line 3449
nsOutlinerSelection::FireOnSelectHandler() line 728
nsOutlinerSelection::AdjustSelection(nsOutlinerSelection * const 0x081c9200, 
int 0, int 118) line 687
nsOutlinerBodyFrame::RowCountChanged(nsOutlinerBodyFrame * const 0x0531c84c, 
int 0, int 118) line 1330
nsOutlinerBoxObject::RowCountChanged(nsOutlinerBoxObject * const 0x0649b7f0, 
int 0, int 118) line 386 + 20 bytes
nsMsgDBView::AdjustRowCount(int 439, int 321) line 4909
nsMsgThreadedDBView::Sort(nsMsgThreadedDBView * const 0x070b2570, int 22, int 
1) line 263 + 21 bytes
XPTC_InvokeByIndex(nsISupports * 0x070b2570, unsigned int 6, unsigned int 2, 
nsXPTCVariant * 0x0012ccfc) line 106
XPCWrappedNative::CallMethod(XPCCallContext & {...}, XPCWrappedNative::CallMode 
CALL_METHOD) line 2009 + 42 bytes
XPC_WN_CallMethod(JSContext * 0x017b8430, JSObject * 0x05302690, unsigned int 
2, long * 0x058ae1d0, long * 0x0012cfd0) line 1266 + 14 bytes
js_Invoke(JSContext * 0x017b8430, unsigned int 2, unsigned int 0) line 832 + 23 
bytes
js_Interpret(JSContext * 0x017b8430, long * 0x0012ddc0) line 2798 + 15 bytes
js_Invoke(JSContext * 0x017b8430, unsigned int 1, unsigned int 2) line 849 + 13 
bytes
nsXPCWrappedJSClass::CallMethod(nsXPCWrappedJSClass * const 0x037ddf80, 
nsXPCWrappedJS * 0x065092f0, unsigned short 3, const nsXPTMethodInfo * 
0x0100dcb0, nsXPTCMiniVariant * 0x0012e308) line 1216 + 21 bytes
nsXPCWrappedJS::CallMethod(nsXPCWrappedJS * const 0x065092f0, unsigned short 3, 
const nsXPTMethodInfo * 0x0100dcb0, nsXPTCMiniVariant * 0x0012e308) line 430
PrepareAndDispatch(nsXPTCStubBase * 0x065092f0, unsigned int 3, unsigned int * 
0x0012e3b8, unsigned int * 0x0012e3a8) line 115 + 31 bytes
SharedStub() line 139
nsEventListenerManager::HandleEventSubType(nsListenerStruct * 0x06509ce0, 
nsIDOMEvent * 0x063958c8, nsIDOMEventTarget * 0x062c3ca8, unsigned int 4, 
unsigned int 4) line 1205 + 20 bytes
nsEventListenerManager::HandleEvent(nsEventListenerManager * const 0x062c3bf0, 
nsIPresContext * 0x017d25f0, nsEvent * 0x0012f500, nsIDOMEvent * * 0x0012f408, 
nsIDOMEventTarget * 0x062c3ca8, unsigned int 4, nsEventStatus * 0x0012f828) 
line 1373 + 36 bytes
nsXULElement::HandleDOMEvent(nsXULElement * const 0x062c3ca0, nsIPresContext * 
0x017d25f0, nsEvent * 0x0012f500, nsIDOMEvent * * 0x0012f408, unsigned int 4, 
nsEventStatus * 0x0012f828) line 3449
nsXULElement::HandleDOMEvent(nsXULElement * const 0x055e3740, nsIPresContext * 
0x017d25f0, nsEvent * 0x0012f500, nsIDOMEvent * * 0x0012f408, unsigned int 4, 
nsEventStatus * 0x0012f828) line 3430
nsXULElement::HandleDOMEvent(nsXULElement * const 0x055e3690, nsIPresContext * 
0x017d25f0, nsEvent * 0x0012f500, nsIDOMEvent * * 0x0012f408, unsigned int 1, 
nsEventStatus * 0x0012f828) line 3430
PresShell::HandleEventInternal(nsEvent * 0x0012f500, nsIView * 0x00000000, 
unsigned int 1, nsEventStatus * 0x0012f828) line 6060 + 44 bytes
PresShell::HandleEventWithTarget(PresShell * const 0x017dc030, nsEvent * 
0x0012f500, nsIFrame * 0x05315738, nsIContent * 0x055e3690, unsigned int 1, 
nsEventStatus * 0x0012f828) line 6031 + 22 bytes
nsEventStateManager::CheckForAndDispatchClick(nsEventStateManager * const 
0x0626b0a0, nsIPresContext * 0x017d25f0, nsMouseEvent * 0x0012f930, 
nsEventStatus * 0x0012f828) line 2462 + 63 bytes
nsEventStateManager::PostHandleEvent(nsEventStateManager * const 0x0626b0a8, 
nsIPresContext * 0x017d25f0, nsEvent * 0x0012f930, nsIFrame * 0x05315738, 
nsEventStatus * 0x0012f828, nsIView * 0x017d45f0) line 1544 + 28 bytes
PresShell::HandleEventInternal(nsEvent * 0x0012f930, nsIView * 0x017d45f0, 
unsigned int 1, nsEventStatus * 0x0012f828) line 6080 + 43 bytes
PresShell::HandleEvent(PresShell * const 0x017dc034, nsIView * 0x017d45f0, 
nsGUIEvent * 0x0012f930, nsEventStatus * 0x0012f828, int 1, int & 1) line 5985 
+ 25 bytes
nsView::HandleEvent(nsView * const 0x017d45f0, nsGUIEvent * 0x0012f930, 
unsigned int 0, nsEventStatus * 0x0012f828, int 1, int & 1) line 387
nsViewManager::DispatchEvent(nsViewManager * const 0x017d4790, nsGUIEvent * 
0x0012f930, nsEventStatus * 0x0012f828) line 1930
HandleEvent(nsGUIEvent * 0x0012f930) line 83
nsWindow::DispatchEvent(nsWindow * const 0x017d1854, nsGUIEvent * 0x0012f930, 
nsEventStatus & nsEventStatus_eIgnore) line 846 + 10 bytes
nsWindow::DispatchWindowEvent(nsGUIEvent * 0x0012f930) line 867
nsWindow::DispatchMouseEvent(unsigned int 301, nsPoint * 0x00000000) line 4441 
+ 21 bytes
ChildWindow::DispatchMouseEvent(unsigned int 301, nsPoint * 0x00000000) line 
4693
nsWindow::ProcessMessage(unsigned int 514, unsigned int 0, long 7733561, long * 
0x0012fd24) line 3368 + 24 bytes
nsWindow::WindowProc(HWND__ * 0x000104a8, unsigned int 514, unsigned int 0, 
long 7733561) line 1111 + 27 bytes
USER32! 77e13eb0()
USER32! 77e1401a()
USER32! 77e192da()
nsAppShellService::Run(nsAppShellService * const 0x00578c80) line 303
main1(int 1, char * * 0x004847f0, nsISupports * 0x00000000) line 1264 + 32 bytes
main(int 1, char * * 0x004847f0) line 1594 + 37 bytes
mainCRTStartup() line 338 + 17 bytes
KERNEL32! 77e87903()

crash:


nsUInt32Array::GetAt(unsigned int 3452816845) line 143 + 9 bytes
nsMsgDBView::OfflineMsgSelected(unsigned int * 0x081c5260, int 321) line 4860 + 
22 bytes
nsMsgDBView::SelectionChanged(nsMsgDBView * const 0x070b2578) line 884 + 25 
bytes
XPTC_InvokeByIndex(nsISupports * 0x070b2578, unsigned int 24, unsigned int 0, 
nsXPTCVariant * 0x0012ac40) line 106
XPCWrappedNative::CallMethod(XPCCallContext & {...}, XPCWrappedNative::CallMode 
CALL_METHOD) line 2009 + 42 bytes
XPC_WN_CallMethod(JSContext * 0x017b8430, JSObject * 0x05302690, unsigned int 
0, long * 0x058ae1fc, long * 0x0012af14) line 1266 + 14 bytes
js_Invoke(JSContext * 0x017b8430, unsigned int 0, unsigned int 0) line 832 + 23 
bytes
js_Interpret(JSContext * 0x017b8430, long * 0x0012bd04) line 2798 + 15 bytes
js_Invoke(JSContext * 0x017b8430, unsigned int 1, unsigned int 2) line 849 + 13 
bytes
js_InternalInvoke(JSContext * 0x017b8430, JSObject * 0x05302138, long 86666152, 
unsigned int 0, unsigned int 1, long * 0x0012bf74, long * 0x0012be2c) line 924 
+ 20 bytes
JS_CallFunctionValue(JSContext * 0x017b8430, JSObject * 0x05302138, long 
86666152, unsigned int 1, long * 0x0012bf74, long * 0x0012be2c) line 3405 + 31 
bytes
nsJSContext::CallEventHandler(nsJSContext * const 0x017be120, void * 
0x05302138, void * 0x052a6ba8, unsigned int 1, void * 0x0012bf74, int * 
0x0012bf78, int 0) line 1011 + 33 bytes
nsJSEventListener::HandleEvent(nsJSEventListener * const 0x063d2eb0, 
nsIDOMEvent * 0x082337d8) line 180 + 77 bytes
nsEventListenerManager::HandleEventSubType(nsListenerStruct * 0x063d2e10, 
nsIDOMEvent * 0x082337d8, nsIDOMEventTarget * 0x055e2b18, unsigned int 8, 
unsigned int 7) line 1205 + 20 bytes
nsEventListenerManager::HandleEvent(nsEventListenerManager * const 0x063d2f00, 
nsIPresContext * 0x017d25f0, nsEvent * 0x0012c9c4, nsIDOMEvent * * 0x0012c954, 
nsIDOMEventTarget * 0x055e2b18, unsigned int 7, nsEventStatus * 0x0012c9ec) 
line 1806 + 36 bytes
nsXULElement::HandleDOMEvent(nsXULElement * const 0x055e2b10, nsIPresContext * 
0x017d25f0, nsEvent * 0x0012c9c4, nsIDOMEvent * * 0x0012c954, unsigned int 1, 
nsEventStatus * 0x0012c9ec) line 3449
nsOutlinerSelection::FireOnSelectHandler() line 728
nsOutlinerSelection::AdjustSelection(nsOutlinerSelection * const 0x081c9200, 
int 0, int 118) line 687
nsOutlinerBodyFrame::RowCountChanged(nsOutlinerBodyFrame * const 0x0531c84c, 
int 0, int 118) line 1330
nsOutlinerBoxObject::RowCountChanged(nsOutlinerBoxObject * const 0x0649b7f0, 
int 0, int 118) line 386 + 20 bytes
nsMsgDBView::AdjustRowCount(int 439, int 321) line 4909
nsMsgThreadedDBView::Sort(nsMsgThreadedDBView * const 0x070b2570, int 22, int 
1) line 263 + 21 bytes
XPTC_InvokeByIndex(nsISupports * 0x070b2570, unsigned int 6, unsigned int 2, 
nsXPTCVariant * 0x0012ccfc) line 106
XPCWrappedNative::CallMethod(XPCCallContext & {...}, XPCWrappedNative::CallMode 
CALL_METHOD) line 2009 + 42 bytes
XPC_WN_CallMethod(JSContext * 0x017b8430, JSObject * 0x05302690, unsigned int 
2, long * 0x058ae1d0, long * 0x0012cfd0) line 1266 + 14 bytes
js_Invoke(JSContext * 0x017b8430, unsigned int 2, unsigned int 0) line 832 + 23 
bytes
js_Interpret(JSContext * 0x017b8430, long * 0x0012ddc0) line 2798 + 15 bytes
js_Invoke(JSContext * 0x017b8430, unsigned int 1, unsigned int 2) line 849 + 13 
bytes
nsXPCWrappedJSClass::CallMethod(nsXPCWrappedJSClass * const 0x037ddf80, 
nsXPCWrappedJS * 0x065092f0, unsigned short 3, const nsXPTMethodInfo * 
0x0100dcb0, nsXPTCMiniVariant * 0x0012e308) line 1216 + 21 bytes
nsXPCWrappedJS::CallMethod(nsXPCWrappedJS * const 0x065092f0, unsigned short 3, 
const nsXPTMethodInfo * 0x0100dcb0, nsXPTCMiniVariant * 0x0012e308) line 430
PrepareAndDispatch(nsXPTCStubBase * 0x065092f0, unsigned int 3, unsigned int * 
0x0012e3b8, unsigned int * 0x0012e3a8) line 115 + 31 bytes
SharedStub() line 139
nsEventListenerManager::HandleEventSubType(nsListenerStruct * 0x06509ce0, 
nsIDOMEvent * 0x063958c8, nsIDOMEventTarget * 0x062c3ca8, unsigned int 4, 
unsigned int 4) line 1205 + 20 bytes
nsEventListenerManager::HandleEvent(nsEventListenerManager * const 0x062c3bf0, 
nsIPresContext * 0x017d25f0, nsEvent * 0x0012f500, nsIDOMEvent * * 0x0012f408, 
nsIDOMEventTarget * 0x062c3ca8, unsigned int 4, nsEventStatus * 0x0012f828) 
line 1373 + 36 bytes
nsXULElement::HandleDOMEvent(nsXULElement * const 0x062c3ca0, nsIPresContext * 
0x017d25f0, nsEvent * 0x0012f500, nsIDOMEvent * * 0x0012f408, unsigned int 4, 
nsEventStatus * 0x0012f828) line 3449
nsXULElement::HandleDOMEvent(nsXULElement * const 0x055e3740, nsIPresContext * 
0x017d25f0, nsEvent * 0x0012f500, nsIDOMEvent * * 0x0012f408, unsigned int 4, 
nsEventStatus * 0x0012f828) line 3430
nsXULElement::HandleDOMEvent(nsXULElement * const 0x055e3690, nsIPresContext * 
0x017d25f0, nsEvent * 0x0012f500, nsIDOMEvent * * 0x0012f408, unsigned int 1, 
nsEventStatus * 0x0012f828) line 3430
PresShell::HandleEventInternal(nsEvent * 0x0012f500, nsIView * 0x00000000, 
unsigned int 1, nsEventStatus * 0x0012f828) line 6060 + 44 bytes
PresShell::HandleEventWithTarget(PresShell * const 0x017dc030, nsEvent * 
0x0012f500, nsIFrame * 0x05315738, nsIContent * 0x055e3690, unsigned int 1, 
nsEventStatus * 0x0012f828) line 6031 + 22 bytes
nsEventStateManager::CheckForAndDispatchClick(nsEventStateManager * const 
0x0626b0a0, nsIPresContext * 0x017d25f0, nsMouseEvent * 0x0012f930, 
nsEventStatus * 0x0012f828) line 2462 + 63 bytes
nsEventStateManager::PostHandleEvent(nsEventStateManager * const 0x0626b0a8, 
nsIPresContext * 0x017d25f0, nsEvent * 0x0012f930, nsIFrame * 0x05315738, 
nsEventStatus * 0x0012f828, nsIView * 0x017d45f0) line 1544 + 28 bytes
PresShell::HandleEventInternal(nsEvent * 0x0012f930, nsIView * 0x017d45f0, 
unsigned int 1, nsEventStatus * 0x0012f828) line 6080 + 43 bytes
PresShell::HandleEvent(PresShell * const 0x017dc034, nsIView * 0x017d45f0, 
nsGUIEvent * 0x0012f930, nsEventStatus * 0x0012f828, int 1, int & 1) line 5985 
+ 25 bytes
nsView::HandleEvent(nsView * const 0x017d45f0, nsGUIEvent * 0x0012f930, 
unsigned int 0, nsEventStatus * 0x0012f828, int 1, int & 1) line 387
nsViewManager::DispatchEvent(nsViewManager * const 0x017d4790, nsGUIEvent * 
0x0012f930, nsEventStatus * 0x0012f828) line 1930
HandleEvent(nsGUIEvent * 0x0012f930) line 83
nsWindow::DispatchEvent(nsWindow * const 0x017d1854, nsGUIEvent * 0x0012f930, 
nsEventStatus & nsEventStatus_eIgnore) line 846 + 10 bytes
nsWindow::DispatchWindowEvent(nsGUIEvent * 0x0012f930) line 867
nsWindow::DispatchMouseEvent(unsigned int 301, nsPoint * 0x00000000) line 4441 
+ 21 bytes
ChildWindow::DispatchMouseEvent(unsigned int 301, nsPoint * 0x00000000) line 
4693
nsWindow::ProcessMessage(unsigned int 514, unsigned int 0, long 7733561, long * 
0x0012fd24) line 3368 + 24 bytes
nsWindow::WindowProc(HWND__ * 0x000104a8, unsigned int 514, unsigned int 0, 
long 7733561) line 1111 + 27 bytes
USER32! 77e13eb0()
USER32! 77e1401a()
USER32! 77e192da()
nsAppShellService::Run(nsAppShellService * const 0x00578c80) line 303
main1(int 1, char * * 0x004847f0, nsISupports * 0x00000000) line 1264 + 32 bytes
main(int 1, char * * 0x004847f0) line 1594 + 37 bytes
mainCRTStartup() line 338 + 17 bytes
KERNEL32! 77e87903()
see also 118137, which has the same crash, but probably a different cause. In
both cases, the selection is out of sync/invalid with the flags array.
debugging now.

in nsMsgDBView::SelectionChanged()

it looks like we think GetNumSelected() returns more than what 
GetSelectedIndices() has.

working on it...
still working on this.

I've made sure that we are always calling RowCountChanged() after we've 
adjusted m_keys, because RowCountChanged() will call our GetRowCount(), which 
uses m_keys.

I've added comments to all callers, so that anyone adding calls in the future 
(cut-n-paste or by looking at existing code) will hopefully heed the comments.

but the cause of this problem is starting to look like we're calling 
AdjustRowCount() and we've got a selection, and that's not safe.

I've added an assert to AdjustRowCount(), which is catching this problem, and 
now I'm working on fixing it.
we need to clear the selection, after saving it.

that fixes the problems.  here comes the patch.
The problem here appears to be sort calling InitThreadedView that calls
InitSort that calls sort again - a bit odd. 

If i prevent this meaning just return InitThreadedView, that fixes the 
problem

Attached patch proposed fix (obsolete) — Splinter Review
possible patch, added a boolean to prevent sorting when called from within
Sort. I have to test it more, but going back and forth between threaded and 
flat view works.
part of my current patch (still testing) involves this:

+  // if there is a selection, make sure the currentView was preserved....
+  if (arraySize && m_currentlyDisplayedMsgKey != nsMsgKey_None)

the reason for the "arraySize &&" change is because when we go from flat to 
threaded, we end up calling Sort() twice, which does this:

SaveSelection()
ClearSelection()
  SaveSelection() // saves nothing
  ClearSelection() // clears nothing
  RestoreSelection() // restores nothing, but then selects 
m_currentlyDisplayedMsgKey, has item selected
RestoreSelection() // AdjustRowCount() will assert, since one item selected.

by adding the check "arraySize &&", this will only reload the selected message

it might be that we need to clear m_currentlyDisplayedMsgKey, 
or not call Sort() from Sort()

nsMsgDBView::RestoreSelection(nsMsgKeyArray * 0x0012bcac) line 735
nsMsgThreadedDBView::Sort(nsMsgThreadedDBView * const 0x05376940, int 22, int 
1) line 305
nsMsgThreadedDBView::InitSort(int 22, int 1) line 527
nsMsgThreadedDBView::InitThreadedView(int * 0x00000000) line 174 + 37 bytes
nsMsgThreadedDBView::Sort(nsMsgThreadedDBView * const 0x05376940, int 22, int 
1) line 263
XPTC_InvokeByIndex(nsISupports * 0x05376940, unsigned int 6, unsigned int 2, 
nsXPTCVariant * 0x0012ccfc) line 106
taking to jglick, we are supposed to be clearing the message pane (and 
therefore setting m_currentlyDisplayedMsgKey = nsMsgKey_None) when we have 
multiple selection.

so if we fix that, I won't need the "(arraySize &&" bit, since we won't be 
asserting when we call AdjustRowCount() when we go from flat (all selected) to 
threaded because selecting all with reset m_currentlyDisplayedMsgKey

working on a patch that does that, that asserts if we have a selection in 
AdjustRowCount(), clears selection after saving the selection, and makes sure 
we call RowCountChanged() only after we've modified m_keys.

the call to clear selection fixes this crasher.  but I believe all those 
changes to be necessary and correct.  

I'm not sure yet whether preventing sort from calling sort is necessary or 
correct, I'll look into that next.
having sort() call sort() may have performance problems, for this reason:

save()
  save()
  restore()  <-- this call to restore selection will cause us to suppressing 
                 selection events.
[***stuff we do here that causes selection events will not be ignored]
restore()

so if go from flat to threaded, especially when you select all, we can waste a 
lot of time in ***.

I'll continue to investigate.

we need sort to call sort, otherwise the threaded view is broken.  (naving, can
you confirm?  I tried your patch and my threaded view was not properly sorted)

this patch, in addition to fixing this crasher, fixes the bug where we should
be blanking out the message pane (and the ab card pane) when more that one item
is selected.

the sort() calling sort() is a problem because we don't handle nested calls to
Save / Restore selection.

the inner call to restore selection will stop suppressing the selection
changes.

to fix this, I keep track of the depth for save / restore calls.  only the
outer most calls (when they are nested) will do anything.
Attachment #63546 - Attachment is obsolete: true
Attached patch updated patchSplinter Review
update the patch.  the last patch would clear the message pane on delete.

now, it only clears when we go from one selected item to more than one.
Attachment #63621 - Attachment is obsolete: true
Comment on attachment 63628 [details] [diff] [review]
updated patch

looks good, sr=bienvenu
have you tried the standalone message window, just for fun?
Attachment #63628 - Flags: superreview+
yes, I've tested the stand alone msg window. 

next and delete work, as does deleting the last msg in a folder from it.

also, I tested search and quick search and opening a message (in the 3 pane) 
from the advanced search dialog.
fixed.
Status: ASSIGNED → RESOLVED
Closed: 23 years ago
Resolution: --- → FIXED
QA Contact: esther → laurel
No longer blocks: 118137
OK for IMAP folders -- tried with varied size folders 1,500-11,000 messages. All
okay, threading seems to take place within a somewhat reasonable amount of time
(found it to be slowest on mac).

Not real good on newsgroups -- whew.  Will do some more testing and open a
separate bug if I confirm it consistently has problems... So far in two tries,
app hangs. I waited a few minutes before ending the task.

Anyway, marking this mail folder scenario verified.
OK using feb04 commercial trunk build: win98, linux rh6.2, mac OS 10.1
Status: RESOLVED → VERIFIED
News scenario doesn't consistently hang or crash. Will log specific instance(s)
bugs, but in general it works okay with reasonably sized newsgroups. Fails only
sometimes on larger groups (20,000+ messages). 
Product: Browser → Seamonkey
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: