Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
V
vlc
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Redmine
Redmine
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Metrics
Environments
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
videolan
vlc
Commits
c57a8be4
Commit
c57a8be4
authored
Aug 16, 2008
by
Pierre d'Herbemont
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
real: Protect against negative size reading.
Should fix a crash reported by the bugreport ml.
parent
1804ded9
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
10 additions
and
1 deletion
+10
-1
modules/demux/real.c
modules/demux/real.c
+10
-1
No files found.
modules/demux/real.c
View file @
c57a8be4
...
...
@@ -269,7 +269,8 @@ static int Demux( demux_t *p_demux )
{
demux_sys_t
*
p_sys
=
p_demux
->
p_sys
;
uint8_t
header
[
18
];
int
i_size
,
i_id
,
i_flags
,
i
;
int
i_id
,
i_flags
,
i
;
unsigned
int
i_size
;
int64_t
i_pts
;
real_track_t
*
tk
=
NULL
;
bool
b_selected
;
...
...
@@ -310,6 +311,14 @@ static int Demux( demux_t *p_demux )
p_sys
->
i_data_packets
++
;
if
(
i_size
==
0
)
return
0
;
if
(
i_size
>
sizeof
(
p_sys
->
buffer
)
)
{
msg_Err
(
p_demux
,
"Got a size to read bigger than our buffer. Ignoring current frame."
);
return
0
;
}
stream_Read
(
p_demux
->
s
,
p_sys
->
buffer
,
i_size
);
for
(
i
=
0
;
i
<
p_sys
->
i_track
;
i
++
)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment