Closed
Bug 148713
Opened 23 years ago
Closed 23 years ago
infinite loop in search/replace
Categories
(SeaMonkey :: UI Design, defect)
SeaMonkey
UI Design
Tracking
(Not tracked)
VERIFIED
FIXED
mozilla1.0.1
People
(Reporter: mozeditor, Assigned: akkzilla)
References
Details
(Whiteboard: [ADT2 RTM] [ETA 07/01])
Attachments
(1 file, 1 obsolete file)
3.74 KB,
patch
|
Brade
:
review+
kinmoz
:
superreview+
jud
:
approval+
|
Details | Diff | Splinter Review |
from #composer channel on mozilla irc:
5:45 PM: *** brantgurga
(chatzilla@dialup-65.58.70.147.Dial1.Indianapolis1.Level3.net) has joined
channel #composer
55:46 PM: brantgurga: Search and Replace has a bug
5:46 PM: brantgurga: Try replacing "test" with "this test" and click replace all.
5:46 PM: brantgurga: Recursive searching causes infinite loop.
Reporter | ||
Comment 1•23 years ago
|
||
Did I pick the correct component? cc'ing Akkana and Kin.
Assignee | ||
Comment 2•23 years ago
|
||
I'm not sure what the right component is, but this would probably be my bug.
But I don't see it. What page were you editing? I tried just copying the text
of this bug and pasting it into a composer page (so the word "test" appeared a
couple of times), setting the caret near the beginning of the file, then
replacing "test" with "this test" and clicking replace all. It did the replace,
no infinite loop.
On what version of mozilla did you see this? I tried on a branch release build
and on a current trunk build.
Comment 3•23 years ago
|
||
Managed to reproduce this with today's branch. Steps:
1) Edit this bug in Composer
2) Hit Ctrl-F
3) Text to find is "test" and text to replace with is "test this"
4) Select wrap around and search backwards
5) Replace all
Hangs with 100% cpu and eventually crashes.
Assignee | ||
Comment 4•23 years ago
|
||
Yup! I see it too. Taking the bug.
Assignee: sgehani → akkana
Target Milestone: --- → mozilla1.0.1
Assignee | ||
Comment 5•23 years ago
|
||
Fix coming, cc some possible reviewers, add ADT2 hoping there might be a chance
to get this into MachV since it's a hang and it's not that unusual a case.
Status: NEW → ASSIGNED
Whiteboard: ADT2
Assignee | ||
Comment 6•23 years ago
|
||
The code made the assumption that the inserted text would end up selected. In
fact, the editor puts the selection after the inserted text, so we were finding
it on the next iteration. (I thought I checked for that case, but I guess I
only checked for it in the forward direction).
The only solution I found was to save the selection by collapsing the found
range before inserting, in the reverse direction. That doesn't work in the
forward direction, though, apparently because of the direction that range
gravity collapses the range after the selected contents disappear, so in the
forward direction I kept the existing code.
Seeking review -- Joe? Charley? Kathy?
Assignee | ||
Comment 7•23 years ago
|
||
This file generated some JS strict warnings -- let's fix them as long as we're
in here, since it's just a couple lines more. I've included fixes for all the
warnings I could find.
Attachment #86734 -
Attachment is obsolete: true
Comment 8•23 years ago
|
||
Comment on attachment 86744 [details] [diff] [review]
Include strict warning fixes (bug 145071)
r=brade
Attachment #86744 -
Flags: review+
Comment on attachment 86744 [details] [diff] [review]
Include strict warning fixes (bug 145071)
sr=kin@netscape.com
Attachment #86744 -
Flags: superreview+
Assignee | ||
Comment 10•23 years ago
|
||
Fixed on trunk. Adding adt1.0.1 keyword to request branch checkin, since this
fixes a hang.
Updated•23 years ago
|
Whiteboard: ADT2 → [ADT2 RTM] [ETA 06/24]
Assignee | ||
Comment 11•23 years ago
|
||
In response to an ADT question: this patch does not involve any string changes.
Updated•23 years ago
|
Comment 12•23 years ago
|
||
VERIFIED Fixed on the trunk with 20020627 builds.
Turns out this was the wrong component. reassigning, if there need be any
follow-up the right QA can help you out.but in the meantime -to save time- this
bug _is_ 'verified' on trunk builds.
Status: RESOLVED → VERIFIED
Component: Search → XP Apps: GUI Features
QA Contact: claudius
Comment 13•23 years ago
|
||
adt1.0.1+ (on ADT's behalf) approval for checkin to the 1.0 branch, pending
drivers' approval. pls check this in asap, then add the "fixed1.0.1" keyword.
Updated•23 years ago
|
Attachment #86744 -
Flags: approval+
Comment 14•23 years ago
|
||
please checkin to the 1.0.1 branch. once there, remove the "mozilla1.0.1+"
keyword and add the "fixed1.0.1" keyword.
Keywords: mozilla1.0.1 → mozilla1.0.1+
Comment 16•22 years ago
|
||
verified on 1.0.1branch win2k build 8-23.
Keywords: fixed1.0.1 → verified1.0.1
Updated•20 years ago
|
Product: Core → Mozilla Application Suite
You need to log in
before you can comment on or make changes to this bug.
Description
•