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
b092aef5
Commit
b092aef5
authored
Aug 27, 2015
by
Rémi Denis-Courmont
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
mmsh: fix URLs with query and no path
parent
75e2a6cf
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
11 additions
and
7 deletions
+11
-7
modules/access/mms/mmsh.c
modules/access/mms/mmsh.c
+10
-6
modules/access/mms/mmstu.c
modules/access/mms/mmstu.c
+1
-1
No files found.
modules/access/mms/mmsh.c
View file @
b092aef5
...
...
@@ -105,7 +105,7 @@ int MMSHOpen( access_t *p_access )
if
(
psz_proxy
)
{
p_sys
->
b_proxy
=
true
;
vlc_UrlParse
(
&
p_sys
->
proxy
,
psz_proxy
,
0
);
vlc_UrlParse
(
&
p_sys
->
proxy
,
psz_proxy
,
'?'
);
free
(
psz_proxy
);
}
else
...
...
@@ -114,7 +114,7 @@ int MMSHOpen( access_t *p_access )
if
(
http_proxy
)
{
p_sys
->
b_proxy
=
true
;
vlc_UrlParse
(
&
p_sys
->
proxy
,
http_proxy
,
0
);
vlc_UrlParse
(
&
p_sys
->
proxy
,
http_proxy
,
'?'
);
}
}
...
...
@@ -136,7 +136,7 @@ int MMSHOpen( access_t *p_access )
}
/* open a tcp connection */
vlc_UrlParse
(
&
p_sys
->
url
,
p_access
->
psz_location
,
0
);
vlc_UrlParse
(
&
p_sys
->
url
,
p_access
->
psz_location
,
'?'
);
if
(
(
p_sys
->
url
.
psz_host
==
NULL
)
||
(
*
p_sys
->
url
.
psz_host
==
'\0'
)
)
{
...
...
@@ -531,11 +531,13 @@ static int OpenConnection( access_t *p_access )
if
(
p_sys
->
b_proxy
)
{
net_Printf
(
p_access
,
p_sys
->
fd
,
"GET http://%s:%d%s HTTP/1.0
\r\n
"
,
net_Printf
(
p_access
,
p_sys
->
fd
,
"GET http://%s:%d%s
%s%s
HTTP/1.0
\r\n
"
,
p_sys
->
url
.
psz_host
,
p_sys
->
url
.
i_port
,
(
(
p_sys
->
url
.
psz_path
==
NULL
)
||
(
*
p_sys
->
url
.
psz_path
==
'\0'
)
)
?
"/"
:
p_sys
->
url
.
psz_path
);
"/"
:
p_sys
->
url
.
psz_path
,
p_sys
->
url
.
psz_option
?
"?"
:
""
,
p_sys
->
url
.
psz_option
?
p_sys
->
url
.
psz_option
:
""
);
/* Proxy Authentication */
if
(
p_sys
->
proxy
.
psz_username
&&
*
p_sys
->
proxy
.
psz_username
)
...
...
@@ -557,11 +559,13 @@ static int OpenConnection( access_t *p_access )
}
else
{
net_Printf
(
p_access
,
p_sys
->
fd
,
"GET %s HTTP/1.0
\r\n
"
net_Printf
(
p_access
,
p_sys
->
fd
,
"GET %s
%s%s
HTTP/1.0
\r\n
"
"Host: %s:%d
\r\n
"
,
(
(
p_sys
->
url
.
psz_path
==
NULL
)
||
(
*
p_sys
->
url
.
psz_path
==
'\0'
)
)
?
"/"
:
p_sys
->
url
.
psz_path
,
p_sys
->
url
.
psz_option
?
"?"
:
""
,
p_sys
->
url
.
psz_option
?
p_sys
->
url
.
psz_option
:
""
,
p_sys
->
url
.
psz_host
,
p_sys
->
url
.
i_port
);
}
return
VLC_SUCCESS
;
...
...
modules/access/mms/mmstu.c
View file @
b092aef5
...
...
@@ -105,7 +105,7 @@ int MMSTUOpen( access_t *p_access )
vlc_mutex_init
(
&
p_sys
->
lock_netwrite
);
/* *** Parse URL and get server addr/port and path *** */
vlc_UrlParse
(
&
p_sys
->
url
,
p_access
->
psz_location
,
0
);
vlc_UrlParse
(
&
p_sys
->
url
,
p_access
->
psz_location
,
'?'
);
if
(
p_sys
->
url
.
psz_host
==
NULL
||
*
p_sys
->
url
.
psz_host
==
'\0'
)
{
msg_Err
(
p_access
,
"invalid server name"
);
...
...
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