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
49df0245
Commit
49df0245
authored
Apr 12, 2012
by
Hugo Beauzée-Luyssen
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
zip: Check malloc return.
parent
608be371
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
2 additions
and
0 deletions
+2
-0
modules/access/zip/zipaccess.c
modules/access/zip/zipaccess.c
+2
-0
No files found.
modules/access/zip/zipaccess.c
View file @
49df0245
...
@@ -326,6 +326,8 @@ static int AccessSeek( access_t *p_access, uint64_t seek_len )
...
@@ -326,6 +326,8 @@ static int AccessSeek( access_t *p_access, uint64_t seek_len )
unsigned
i_seek
=
0
;
unsigned
i_seek
=
0
;
int
i_read
=
1
;
int
i_read
=
1
;
char
*
p_buffer
=
(
char
*
)
calloc
(
1
,
ZIP_BUFFER_LEN
);
char
*
p_buffer
=
(
char
*
)
calloc
(
1
,
ZIP_BUFFER_LEN
);
if
(
unlikely
(
!
p_buffer
)
)
return
VLC_EGENERIC
;
while
(
(
i_seek
<
seek_len
)
&&
(
i_read
>
0
)
)
while
(
(
i_seek
<
seek_len
)
&&
(
i_read
>
0
)
)
{
{
i_read
=
(
seek_len
-
i_seek
<
ZIP_BUFFER_LEN
)
i_read
=
(
seek_len
-
i_seek
<
ZIP_BUFFER_LEN
)
...
...
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