[wp-trac] [WordPress Trac] #60428: HTML API: Reset parser state after seeking to bookmark.

WordPress Trac noreply at wordpress.org
Fri Feb 2 22:55:43 UTC 2024


#60428: HTML API: Reset parser state after seeking to bookmark.
--------------------------------------+----------------------
 Reporter:  dmsnell                   |       Owner:  dmsnell
     Type:  defect (bug)              |      Status:  closed
 Priority:  normal                    |   Milestone:  6.5
Component:  HTML API                  |     Version:  trunk
 Severity:  normal                    |  Resolution:  fixed
 Keywords:  has-patch has-unit-tests  |     Focuses:
--------------------------------------+----------------------
Changes (by dmsnell):

 * owner:  (none) => dmsnell
 * status:  new => closed
 * resolution:   => fixed


Comment:

 In [changeset:"57527" 57527]:
 {{{
 #!CommitTicketReference repository="" revision="57527"
 HTML API: Reset parser state after seeking to bookmark.

 When parser states were introduced, nothing in the `seek()` method reset
 the
 parser state. This is problematic because it could leave the parser in the
 wrong state.

 In this patch the parser state is reset so that it's properly adjusted on
 the successive call to `next_token()`.

 Developed in https://github.com/WordPress/wordpress-develop/pull/6021
 Discussed in https://core.trac.wordpress.org/ticket/60428

 Follow-up to [57211]

 Props dmsnell, kevin940726
 Fixes #60428
 }}}

-- 
Ticket URL: <https://core.trac.wordpress.org/ticket/60428#comment:3>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list