Opened 11 years ago
Closed 11 years ago
#8662 closed bug (fixed)
Infinite loop - new to jQuery UI 1.9.0
Reported by: | drew.waddell | Owned by: | |
---|---|---|---|
Priority: | blocker | Milestone: | 1.9.1 |
Component: | ui.resizable | Version: | 1.9.0 |
Keywords: | Cc: | ||
Blocked by: | Blocking: |
Description
An infinite loop can occur when you add and remove a resizable widget to a text area and then call empty on the text area.
I have a set up a jsFiddle showing the bug here: http://jsfiddle.net/dwaddell/a3dxL/
You may have to click the "Add Remove Resizer" a few times.
Thanks for looking into this issue, Drew
Change History (4)
comment:2 Changed 11 years ago by
Milestone: | 1.10.0 → 1.9.1 |
---|---|
Priority: | minor → blocker |
Status: | new → open |
This started with jQuery 1.8.0.
comment:3 Changed 11 years ago by
Specifically this change in .after()
: https://github.com/jquery/jquery/commit/05aff402310d7db5d15f96b15071af6aa21a2afc#L1L161
comment:4 Changed 11 years ago by
Resolution: | → fixed |
---|---|
Status: | open → closed |
Resizable: Use .insertAfter() instead of .after() to avoid recursively destroying. Fixes #8662 - Infinite loop - new to jQuery UI 1.9.0.
Changeset: 025266e00270d155f45550b6838ddd6f4a44470b
I can confirm this. When this situation occurs the code attempts to remove the wrapper on line 215 (https://github.com/jquery/jquery-ui/blob/master/ui/jquery.ui.resizable.js#L215). This will end up re-invoking the outer _destroy method (https://github.com/jquery/jquery-ui/blob/master/ui/jquery.ui.resizable.js#L194) which will again try to remove the wrapper... causing the loop.