Skip to content

Commit

Permalink
Change parse_progress() take JSRef by value. [Issue#5738]
Browse files Browse the repository at this point in the history
  • Loading branch information
JayNakrani committed Apr 19, 2015
1 parent f164cc2 commit 7cdfc76
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions components/script/parse/html.rs
Expand Up @@ -275,7 +275,7 @@ pub fn parse_html(document: JSRef<Document>,
task_state::enter(IN_HTML_PARSER);
}

fn parse_progress(parser: &JSRef<ServoHTMLParser>, url: &Url, load_response: &LoadResponse) {
fn parse_progress(parser: JSRef<ServoHTMLParser>, url: &Url, load_response: &LoadResponse) {
for msg in load_response.progress_port.iter() {
match msg {
ProgressMsg::Payload(data) => {
Expand Down Expand Up @@ -314,10 +314,10 @@ pub fn parse_html(document: JSRef<Document>,
// https://html.spec.whatwg.org/multipage/#read-text
let page = format!("<pre>\u{000A}<plaintext>");
parser.parse_chunk(page);
parse_progress(&parser, url, &load_response);
parse_progress(parser, url, &load_response);
},
_ => {
parse_progress(&parser, url, &load_response);
parse_progress(parser, url, &load_response);
}
}
}
Expand Down

0 comments on commit 7cdfc76

Please sign in to comment.