Bug Tracker

Modify

Ticket #3889 (closed bug: duplicate)

Opened 4 years ago

Last modified 4 years ago

:not selector causes infinit loop on Firefox

Reported by: mihaic Owned by: john
Priority: major Milestone: 1.3.1
Component: selector Version: 1.3
Keywords: :not Cc:
Blocking: Blocked by:

Description

If the selector contains a tag and then a :not it causes an infinit loop on Firefox 3.0.5. Works OK on IE7.

This is the test code to reproduce it:

<!DOCTYPE html PUBLIC "-W3CDTD XHTML 1.0 TransitionalEN" " http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns=" http://www.w3.org/1999/xhtml"> <head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> <script type="text/javascript" src="jquery-1.3.js"></script> <script type="text/javascript">

function bug(){

$("a.myClass:not(.myOtherClass)").addClass("myOtherClass");

}

</script> </head> <body> <a class="myClass myOtherClass">test link</a> <input type="button" value="test" onclick="bug()"/> </body> </html>

Change History

comment:1 Changed 4 years ago by john

  • Status changed from new to closed
  • Resolution set to duplicate

Duplicate of #3837.

Please follow the  bug reporting guidlines and use  jsFiddle when providing test cases and demonstrations instead of pasting the code in the ticket.

View

Add a comment

Modify Ticket

Action
as closed
Author


E-mail address and user name can be saved in the Preferences.

 
Note: See TracTickets for help on using tickets.