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
6b2a31e5
Commit
6b2a31e5
authored
Dec 20, 2015
by
Rémi Denis-Courmont
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
mms: let owner handle HTTP redirection (fixes #4631)
parent
3acdc6d8
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
6 additions
and
32 deletions
+6
-32
modules/access/mms/mmsh.c
modules/access/mms/mmsh.c
+6
-32
No files found.
modules/access/mms/mmsh.c
View file @
6b2a31e5
...
...
@@ -54,7 +54,6 @@ int MMSHOpen ( access_t * );
void
MMSHClose
(
access_t
*
);
static
block_t
*
Block
(
access_t
*
p_access
);
static
ssize_t
ReadRedirect
(
access_t
*
,
uint8_t
*
,
size_t
);
static
int
Seek
(
access_t
*
,
uint64_t
);
static
int
Control
(
access_t
*
,
int
,
va_list
);
...
...
@@ -151,32 +150,16 @@ int MMSHOpen( access_t *p_access )
goto
error
;
/* Handle redirection */
if
(
psz_location
&&
*
psz_location
)
if
(
psz_location
!=
NULL
)
{
msg_Dbg
(
p_access
,
"redirection to %s"
,
psz_location
);
p_access
->
psz_url
=
psz_location
;
input_thread_t
*
p_input
=
p_access
->
p_input
;
input_item_t
*
p_new_loc
;
if
(
!
p_input
)
{
free
(
psz_location
);
goto
error
;
}
/** \bug we do not autodelete here */
p_new_loc
=
input_item_New
(
psz_location
,
psz_location
);
input_item_t
*
p_item
=
input_GetItem
(
p_input
);
input_item_PostSubItem
(
p_item
,
p_new_loc
);
vlc_gc_decref
(
p_new_loc
);
free
(
psz_location
);
p_access
->
pf_block
=
NULL
;
p_access
->
pf_read
=
ReadRedirect
;
return
VLC_SUCCESS
;
vlc_UrlClean
(
&
p_sys
->
url
);
vlc_UrlClean
(
&
p_sys
->
proxy
);
free
(
p_sys
);
return
VLC_ACCESS_REDIRECT
;
}
free
(
psz_location
);
/* Start playing */
if
(
Start
(
p_access
,
0
)
)
...
...
@@ -352,15 +335,6 @@ static int Seek( access_t *p_access, uint64_t i_pos )
return
VLC_SUCCESS
;
}
/*****************************************************************************
* ReadRedirect:
*****************************************************************************/
static
ssize_t
ReadRedirect
(
access_t
*
p_access
,
uint8_t
*
p
,
size_t
i_len
)
{
VLC_UNUSED
(
p_access
);
VLC_UNUSED
(
p
);
VLC_UNUSED
(
i_len
);
return
0
;
}
/*****************************************************************************
* Block:
*****************************************************************************/
...
...
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