New issue
Advanced search Search tips
Note: Color blocks (like or ) mean that a user may not be available. Tooltip shows the reason.

Issue 622615 link

Starred by 3 users

Issue metadata

Status: WontFix
Owner: ----
Closed: May 2018
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: Android
Pri: 2
Type: Bug



Sign in to add a comment

redirect the browser to a new page, show source code!

Reported by lifajing...@gmail.com, Jun 23 2016

Issue description

Example URL:

Steps to reproduce the problem:
OS:android 5.0 
use system webview 

1.  open qian.html
2.  page show source code
3.  redirect  to a new page

What is the expected behavior?

What went wrong?
HTMLDocumentParser.cpp , processParsedChunkFromBackgroundParser funtion.

when location change is pending, throw away some background token.
after redirect  to a new page, still parse the previous page token!

Does it occur on multiple sites: Yes

Is it a problem with a plugin? No 

Did this work before? No 

Does this work in other browsers? Yes 

Chrome version: 53.0.2775.0  Channel: n/a
OS Version: 
Flash Version:
 
IMG_6232_.MP4
1.1 MB View Download
qian.html
105 KB View Download
upload qian.html
Components: Mobile>WebView

Comment 3 by pdr@chromium.org, Jun 23 2016

Components: -Blink Blink>HTML>Parser
lifajing398, can you provide more detailed instructions for how to reproduce this bug?

I think this may be an html parser bug, but I'm not yet sure from the description.

Comment 4 by tkent@chromium.org, Jun 24 2016

Labels: Needs-Feedback
lifajing398, do you mean laoding qian.html reproduces the problem?  Is this reproducible Google Chrome browser, not WebView?


It is difficult to reproduce this bug by Google Chrome browser.

I also think this is an html parser bug.

print log:

E/HTMLDocumentParser( 8489): Inside --> HTMLDocumentParser::didReceiveParsedChunkFromBackgroundParser
E/HTMLDocumentParser( 8489): tokens:type=5,  textPosition start=20,  end=0
E/HTMLDocumentParser( 8489): tokens:type=2,  textPosition start=20,  end=31
E/HTMLDocumentParser( 8489): tokens:type=5,  textPosition start=45,  end=9
E/HTMLDocumentParser( 8489): tokens:type=3,  textPosition start=45,  end=9
E/HTMLDocumentParser( 8489): Inside --> HTMLDocumentParser::didReceiveParsedChunkFromBackgroundParser
E/HTMLDocumentParser( 8489): break  tokens:type=5,  textPosition start=48,  end=1 , locationChangePending=1
E/HTMLDocumentParser( 8489): Inside --> HTMLDocumentParser::didReceiveParsedChunkFromBackgroundParser
E/HTMLDocumentParser( 8489): tokens:type=5,  textPosition start=67,  end=55
E/HTMLDocumentParser( 8489): Inside --> HTMLDocumentParser::didReceiveParsedChunkFromBackgroundParser
E/HTMLDocumentParser( 8489): tokens:type=5,  textPosition start=67,  end=6899
E/HTMLDocumentParser( 8489): Inside --> HTMLDocumentParser::didReceiveParsedChunkFromBackgroundParser
E/HTMLDocumentParser( 8489): tokens:type=5,  textPosition start=75,  end=41
E/HTMLDocumentParser( 8489): Inside --> HTMLDocumentParser::didReceiveParsedChunkFromBackgroundParser
E/HTMLDocumentParser( 8489): tokens:type=5,  textPosition start=89,  end=59
E/HTMLDocumentParser( 8489): Inside --> HTMLDocumentParser::didReceiveParsedChunkFromBackgroundParser
E/HTMLDocumentParser( 8489): tokens:type=5,  textPosition start=97,  end=7061
E/HTMLDocumentParser( 8489): Inside --> HTMLDocumentParser::didReceiveParsedChunkFromBackgroundParser
E/HTMLDocumentParser( 8489): tokens:type=5,  textPosition start=123,  end=2108
E/HTMLDocumentParser( 8489): Inside --> HTMLDocumentParser::didReceiveParsedChunkFromBackgroundParser
E/HTMLDocumentParser( 8489): tokens:type=5,  textPosition start=130,  end=8
E/HTMLDocumentParser( 8489): tokens:type=3,  textPosition start=130,  end=8
E/HTMLDocumentParser( 8489): tokens:type=2,  textPosition start=130,  end=39
E/HTMLDocumentParser( 8489): tokens:type=5,  textPosition start=131,  end=2942
Project Member

Comment 6 by sheriffbot@chromium.org, Jun 24 2016

Labels: -Needs-Feedback Needs-Review
Owner: tkent@chromium.org
Thank you for providing more feedback. Adding requester "tkent@chromium.org" for another review and adding "Needs-Review" label for tracking.

For more details visit https://www.chromium.org/issue-tracking/autotriage - Your friendly Sheriffbot

Comment 7 by tkent@chromium.org, Jun 27 2016

Cc: tkent@chromium.org
Labels: -Needs-Review
Owner: kouhei@chromium.org
kouhei@, any idea about this?

hi kouhei ,tkent

when location change is pending ,  break some start tag,

the html tree building mode become unpredictable.

if redirecting is finish and parse not end of file.

sometime ,the rest of html source show as string.

https://codereview.chromium.org/2107763002/



Comment 9 by kinuko@chromium.org, Jul 27 2016

Labels: Needs-Feedback
lifajing398@: can you clarify the expected & actual behavior a little clearer?  Does just opening qian.html in WebView reproduce the problem, or will the user also need to select 'show source code' manually at some point?  Also: what was the actual (wrong) behavior you observed?

kouhei@: would you be able to triage this / help him land the patch if it makes sense to you?
Cc: kouhei@chromium.org
Owner: dominicc@chromium.org
Status: Assigned (was: Unconfirmed)
Tentatively me I guess but feel free to poach.

The log is interesting, the patch kind of makes sense, and the code does look a bit iffy--peek at the end of the tokens for EOF? Weird.

So maybe to trigger this you need a navigation, with background tokenization, but have the chunk *not* reach EOF token. This probably tickles one of those asserts in debug.
Cc: dominicc@chromium.org
Owner: ----
Status: Available (was: Assigned)
Bulk disowning per sshruthi's email about bug triage best practices.
Cc: ntfschr@chromium.org
Status: WontFix (was: Available)
We haven't received feedback since Jul 27 2016, so I'm just going to assume this has been fixed or isn't a big issue.

Sign in to add a comment