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
e3c88d5d
Commit
e3c88d5d
authored
Sep 16, 2007
by
Rémi Denis-Courmont
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Const cleanup
parent
96b7100a
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
10 additions
and
11 deletions
+10
-11
src/network/tcp.c
src/network/tcp.c
+10
-11
No files found.
src/network/tcp.c
View file @
e3c88d5d
...
...
@@ -54,10 +54,10 @@
#endif
static
int
SocksNegociate
(
vlc_object_t
*
,
int
fd
,
int
i_socks_version
,
c
har
*
psz_socks_user
,
char
*
psz_socks
_passwd
);
c
onst
char
*
psz_user
,
const
char
*
psz
_passwd
);
static
int
SocksHandshakeTCP
(
vlc_object_t
*
,
int
fd
,
int
i_socks_version
,
c
har
*
psz_socks_user
,
char
*
psz_socks
_passwd
,
c
onst
char
*
psz_user
,
const
char
*
psz
_passwd
,
const
char
*
psz_host
,
int
i_port
);
extern
int
net_Socket
(
vlc_object_t
*
p_this
,
int
i_family
,
int
i_socktype
,
int
i_protocol
);
...
...
@@ -240,8 +240,8 @@ next_ai: /* failure */
if
(
psz_socks
!=
NULL
)
{
/* NOTE: psz_socks already free'd! */
char
*
psz_user
=
var_CreateGetString
(
p_this
,
"socks-user"
);
char
*
psz_pwd
=
var_CreateGetString
(
p_this
,
"socks-pwd"
);
char
*
psz_user
=
var_CreateGet
NonEmpty
String
(
p_this
,
"socks-user"
);
char
*
psz_pwd
=
var_CreateGet
NonEmpty
String
(
p_this
,
"socks-pwd"
);
if
(
SocksHandshakeTCP
(
p_this
,
i_handle
,
5
,
psz_user
,
psz_pwd
,
psz_host
,
i_port
)
)
...
...
@@ -336,8 +336,8 @@ int __net_Accept( vlc_object_t *p_this, int pi_fd[], mtime_t i_wait )
*****************************************************************************/
static
int
SocksNegociate
(
vlc_object_t
*
p_obj
,
int
fd
,
int
i_socks_version
,
char
*
psz_socks_user
,
char
*
psz_socks_passwd
)
c
onst
c
har
*
psz_socks_user
,
c
onst
c
har
*
psz_socks_passwd
)
{
uint8_t
buffer
[
128
+
2
*
256
];
int
i_len
;
...
...
@@ -348,8 +348,7 @@ static int SocksNegociate( vlc_object_t *p_obj,
/* We negociate authentication */
if
(
psz_socks_user
&&
psz_socks_passwd
&&
*
psz_socks_user
&&
*
psz_socks_passwd
)
if
(
(
psz_socks_user
==
NULL
)
&&
(
psz_socks_passwd
==
NULL
)
)
b_auth
=
VLC_TRUE
;
buffer
[
0
]
=
i_socks_version
;
/* SOCKS version */
...
...
@@ -427,7 +426,7 @@ static int SocksNegociate( vlc_object_t *p_obj,
static
int
SocksHandshakeTCP
(
vlc_object_t
*
p_obj
,
int
fd
,
int
i_socks_version
,
c
har
*
psz_socks_user
,
char
*
psz_socks
_passwd
,
c
onst
char
*
psz_user
,
const
char
*
psz
_passwd
,
const
char
*
psz_host
,
int
i_port
)
{
uint8_t
buffer
[
128
+
2
*
256
];
...
...
@@ -440,7 +439,7 @@ static int SocksHandshakeTCP( vlc_object_t *p_obj,
if
(
i_socks_version
==
5
&&
SocksNegociate
(
p_obj
,
fd
,
i_socks_version
,
psz_
socks_user
,
psz_socks
_passwd
)
)
psz_
user
,
psz
_passwd
)
)
return
VLC_EGENERIC
;
if
(
i_socks_version
==
4
)
...
...
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