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
90fdcf71
Commit
90fdcf71
authored
Mar 10, 2004
by
Laurent Aimar
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
* httpd: fixed a big mem leak for http streaming.
parent
144bd771
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
13 additions
and
1 deletion
+13
-1
src/misc/httpd.c
src/misc/httpd.c
+13
-1
No files found.
src/misc/httpd.c
View file @
90fdcf71
...
@@ -1293,6 +1293,7 @@ static void httpd_ClientClean( httpd_client_t *cl )
...
@@ -1293,6 +1293,7 @@ static void httpd_ClientClean( httpd_client_t *cl )
if
(
cl
->
fd
>
0
)
if
(
cl
->
fd
>
0
)
{
{
SOCKET_CLOSE
(
cl
->
fd
);
SOCKET_CLOSE
(
cl
->
fd
);
cl
->
fd
=
-
1
;
}
}
httpd_MsgClean
(
&
cl
->
answer
);
httpd_MsgClean
(
&
cl
->
answer
);
...
@@ -1301,6 +1302,7 @@ static void httpd_ClientClean( httpd_client_t *cl )
...
@@ -1301,6 +1302,7 @@ static void httpd_ClientClean( httpd_client_t *cl )
if
(
cl
->
p_buffer
)
if
(
cl
->
p_buffer
)
{
{
free
(
cl
->
p_buffer
);
free
(
cl
->
p_buffer
);
cl
->
p_buffer
=
NULL
;
}
}
}
}
...
@@ -1708,7 +1710,12 @@ static void httpd_ClientSend( httpd_client_t *cl )
...
@@ -1708,7 +1710,12 @@ static void httpd_ClientSend( httpd_client_t *cl )
!
cl
->
b_read_waiting
)
!
cl
->
b_read_waiting
)
{
{
/* catch more body data */
/* catch more body data */
int
i_msg
=
cl
->
query
.
i_type
;
int
i_msg
=
cl
->
query
.
i_type
;
int64_t
i_offset
=
cl
->
answer
.
i_body_offset
;
httpd_MsgClean
(
&
cl
->
answer
);
cl
->
answer
.
i_body_offset
=
i_offset
;
cl
->
url
->
catch
[
i_msg
].
cb
(
cl
->
url
->
catch
[
i_msg
].
p_sys
,
cl
,
cl
->
url
->
catch
[
i_msg
].
cb
(
cl
->
url
->
catch
[
i_msg
].
p_sys
,
cl
,
&
cl
->
answer
,
&
cl
->
query
);
&
cl
->
answer
,
&
cl
->
query
);
}
}
...
@@ -2054,6 +2061,11 @@ static void httpd_HostThread( httpd_host_t *host )
...
@@ -2054,6 +2061,11 @@ static void httpd_HostThread( httpd_host_t *host )
httpd_MsgClean
(
&
cl
->
answer
);
httpd_MsgClean
(
&
cl
->
answer
);
cl
->
answer
.
i_body_offset
=
i_offset
;
cl
->
answer
.
i_body_offset
=
i_offset
;
free
(
cl
->
p_buffer
);
cl
->
p_buffer
=
NULL
;
cl
->
i_buffer
=
0
;
cl
->
i_buffer_size
=
0
;
cl
->
i_state
=
HTTPD_CLIENT_WAITING
;
cl
->
i_state
=
HTTPD_CLIENT_WAITING
;
}
}
}
}
...
...
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