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
fb698859
Commit
fb698859
authored
Sep 08, 2008
by
Rémi Denis-Courmont
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
HTTP access_out: fix binding to an IPv6 address
parent
75412805
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
24 additions
and
33 deletions
+24
-33
modules/access_output/http.c
modules/access_output/http.c
+24
-33
No files found.
modules/access_output/http.c
View file @
fb698859
...
...
@@ -180,45 +180,36 @@ static int Open( vlc_object_t *p_this )
psz_bind_addr
=
psz_parser
=
strdup
(
p_access
->
psz_path
);
i_bind_port
=
0
;
psz_file_name
=
NULL
;
while
(
*
psz_parser
&&
*
psz_parser
!=
':'
&&
*
psz_parser
!=
'/'
)
{
psz_parser
++
;
}
if
(
*
psz_parser
==
':'
)
psz_parser
=
strchr
(
psz_bind_addr
,
'/'
);
if
(
psz_parser
)
{
psz_file_name
=
strdup
(
psz_parser
);
*
psz_parser
=
'\0'
;
psz_parser
++
;
i_bind_port
=
atoi
(
psz_parser
);
while
(
*
psz_parser
&&
*
psz_parser
!=
'/'
)
{
psz_parser
++
;
}
}
if
(
*
psz_parser
==
'/'
)
{
*
psz_parser
=
'\0'
;
psz_parser
++
;
psz_file_name
=
psz_parser
;
}
if
(
psz_file_name
==
NULL
)
{
else
psz_file_name
=
strdup
(
"/"
);
}
else
if
(
*
psz_file_name
!=
'/'
)
{
char
*
p
=
psz_file_name
;
psz_file_name
=
malloc
(
strlen
(
p
)
+
2
);
strcpy
(
psz_file_name
,
"/"
);
strcat
(
psz_file_name
,
p
);
if
(
psz_bind_addr
[
0
]
==
'['
)
{
psz_bind_addr
++
;
psz_parser
=
strstr
(
psz_bind_addr
,
"]:"
);
if
(
psz_parser
)
{
*
psz_parser
=
'\0'
;
i_bind_port
=
atoi
(
psz_parser
+
2
);
}
psz_parser
=
psz_bind_addr
-
1
;
}
else
{
psz_file_name
=
strdup
(
psz_file_name
);
psz_parser
=
strrchr
(
psz_bind_addr
,
':'
);
if
(
psz_parser
)
{
*
psz_parser
=
'\0'
;
i_bind_port
=
atoi
(
psz_parser
+
1
);
}
psz_parser
=
psz_bind_addr
;
}
/* SSL support */
...
...
@@ -249,14 +240,14 @@ static int Open( vlc_object_t *p_this )
if
(
p_sys
->
p_httpd_host
==
NULL
)
{
msg_Err
(
p_access
,
"cannot listen on %s
:
%d"
,
msg_Err
(
p_access
,
"cannot listen on %s
port
%d"
,
psz_bind_addr
,
i_bind_port
);
free
(
psz_file_name
);
free
(
psz_
bind_add
r
);
free
(
psz_
parse
r
);
free
(
p_sys
);
return
VLC_EGENERIC
;
}
free
(
psz_
bind_add
r
);
free
(
psz_
parse
r
);
if
(
p_access
->
psz_access
&&
!
strcmp
(
p_access
->
psz_access
,
"mmsh"
)
)
{
...
...
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