Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
V
vlc-1.1
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-1.1
Commits
81c3ec4d
Commit
81c3ec4d
authored
Jan 16, 2009
by
Rémi Duraffort
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
access_mms: use STANDARD_READ_ACCESS_INIT and fix potential memleaks.
parent
4a96b022
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
5 additions
and
17 deletions
+5
-17
modules/access/mms/mmsh.c
modules/access/mms/mmsh.c
+5
-17
No files found.
modules/access/mms/mmsh.c
View file @
81c3ec4d
...
@@ -79,23 +79,7 @@ int MMSHOpen( access_t *p_access )
...
@@ -79,23 +79,7 @@ int MMSHOpen( access_t *p_access )
char
*
psz_location
=
NULL
;
char
*
psz_location
=
NULL
;
char
*
psz_proxy
;
char
*
psz_proxy
;
/* init p_sys */
STANDARD_READ_ACCESS_INIT
/* Set up p_access */
p_access
->
pf_read
=
Read
;
p_access
->
pf_block
=
NULL
;
p_access
->
pf_control
=
Control
;
p_access
->
pf_seek
=
Seek
;
p_access
->
info
.
i_update
=
0
;
p_access
->
info
.
i_size
=
0
;
p_access
->
info
.
i_pos
=
0
;
p_access
->
info
.
b_eof
=
false
;
p_access
->
info
.
i_title
=
0
;
p_access
->
info
.
i_seekpoint
=
0
;
p_access
->
p_sys
=
p_sys
=
calloc
(
1
,
sizeof
(
access_sys_t
)
);
if
(
!
p_sys
)
return
VLC_ENOMEM
;
p_sys
->
i_proto
=
MMS_PROTO_HTTP
;
p_sys
->
i_proto
=
MMS_PROTO_HTTP
;
p_sys
->
fd
=
-
1
;
p_sys
->
fd
=
-
1
;
...
@@ -187,7 +171,10 @@ int MMSHOpen( access_t *p_access )
...
@@ -187,7 +171,10 @@ int MMSHOpen( access_t *p_access )
input_item_t
*
p_new_loc
;
input_item_t
*
p_new_loc
;
if
(
!
p_input
)
if
(
!
p_input
)
{
free
(
psz_location
);
return
VLC_EGENERIC
;
return
VLC_EGENERIC
;
}
/** \bug we do not autodelete here */
/** \bug we do not autodelete here */
p_new_loc
=
input_item_New
(
p_access
,
psz_location
,
psz_location
);
p_new_loc
=
input_item_New
(
p_access
,
psz_location
,
psz_location
);
input_item_AddSubItem
(
input_GetItem
(
p_input
),
p_new_loc
);
input_item_AddSubItem
(
input_GetItem
(
p_input
),
p_new_loc
);
...
@@ -199,6 +186,7 @@ int MMSHOpen( access_t *p_access )
...
@@ -199,6 +186,7 @@ int MMSHOpen( access_t *p_access )
p_access
->
pf_read
=
ReadRedirect
;
p_access
->
pf_read
=
ReadRedirect
;
return
VLC_SUCCESS
;
return
VLC_SUCCESS
;
}
}
free
(
psz_location
);
/* Start playing */
/* Start playing */
if
(
Start
(
p_access
,
0
)
)
if
(
Start
(
p_access
,
0
)
)
...
...
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