Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
V
vlc-gpu
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-gpu
Commits
2c5de8fc
Commit
2c5de8fc
authored
Jul 19, 2009
by
Rémi Denis-Courmont
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
RTP: fix corner-case memory leak (fd_dead is a cancellation point)
parent
43befcc7
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
5 additions
and
4 deletions
+5
-4
modules/access/rtp/input.c
modules/access/rtp/input.c
+5
-4
No files found.
modules/access/rtp/input.c
View file @
2c5de8fc
...
...
@@ -53,22 +53,23 @@ static block_t *rtp_dgram_recv (vlc_object_t *obj, int fd)
block_t
*
block
=
block_Alloc
(
0xffff
);
ssize_t
len
;
block_cleanup_push
(
block
);
do
{
block_cleanup_push
(
block
);
len
=
net_Read
(
obj
,
fd
,
NULL
,
block
->
p_buffer
,
block
->
i_buffer
,
false
);
vlc_cleanup_pop
();
if
(((
len
<=
0
)
&&
fd_dead
(
fd
))
||
!
vlc_object_alive
(
obj
))
{
/* POLLHUP -> permanent (DCCP) socket error */
block_Release
(
block
);
return
NULL
;
block
=
NULL
;
break
;
}
}
while
(
len
==
-
1
);
vlc_cleanup_pop
();
return
block
_Realloc
(
block
,
0
,
len
)
;
return
block
?
block_Realloc
(
block
,
0
,
len
)
:
NULL
;
}
...
...
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