Skip to content
Toggle navigation
Toggle navigation
This project
Loading...
Sign in
brainfood
/
videojs-contrib-hls
Go to a project
Toggle navigation
Toggle navigation pinning
Projects
Groups
Snippets
Help
Project
Activity
Repository
Graphs
Network
Create a new issue
Commits
Issue Boards
Files
Commits
Network
Compare
Branches
Tags
76778e70
authored
2015-05-26 14:40:39 +0200
by
Jernej Fijačko
Committed by
jforbes
2015-05-27 16:23:31 -0400
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
Trim whitespace & newlines in line data before feeding it to the parser
1 parent
4fd2994e
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
1 additions
and
1 deletions
src/m3u8/m3u8-parser.js
src/m3u8/m3u8-parser.js
View file @
76778e7
...
...
@@ -70,7 +70,7 @@
nextNewline
=
buffer
.
indexOf
(
'\n'
);
for
(;
nextNewline
>
-
1
;
nextNewline
=
buffer
.
indexOf
(
'\n'
))
{
this
.
trigger
(
'data'
,
buffer
.
substring
(
0
,
nextNewline
));
this
.
trigger
(
'data'
,
buffer
.
substring
(
0
,
nextNewline
)
.
replace
(
/^
\s
+|
\s
+$/g
,
''
)
);
buffer
=
buffer
.
substring
(
nextNewline
+
1
);
}
};
...
...
Please
register
or
sign in
to post a comment