Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Open sidebar
Main
Synchronet
Commits
30ace4bc
Commit
30ace4bc
authored
Feb 10, 2022
by
Deucе
👌🏾
Browse files
Constify addr_str argument to inet_ptoaddr()
parent
5f119c98
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
2 additions
and
2 deletions
+2
-2
src/xpdev/sockwrap.c
src/xpdev/sockwrap.c
+1
-1
src/xpdev/sockwrap.h
src/xpdev/sockwrap.h
+1
-1
No files found.
src/xpdev/sockwrap.c
View file @
30ace4bc
...
...
@@ -608,7 +608,7 @@ int nonblocking_connect(SOCKET sock, struct sockaddr* addr, size_t size, unsigne
}
union
xp_sockaddr
*
inet_ptoaddr
(
char
*
addr_str
,
union
xp_sockaddr
*
addr
,
size_t
size
)
union
xp_sockaddr
*
inet_ptoaddr
(
const
char
*
addr_str
,
union
xp_sockaddr
*
addr
,
size_t
size
)
{
struct
addrinfo
hints
=
{
0
};
struct
addrinfo
*
res
,
*
cur
;
...
...
src/xpdev/sockwrap.h
View file @
30ace4bc
...
...
@@ -226,7 +226,7 @@ DLLEXPORT int retry_bind(SOCKET s, const struct sockaddr *addr, socklen_t addrle
,
uint
retries
,
uint
wait_secs
,
const
char
*
prot
,
int
(
*
lprintf
)(
int
level
,
const
char
*
fmt
,
...));
DLLEXPORT
int
nonblocking_connect
(
SOCKET
,
struct
sockaddr
*
,
size_t
,
unsigned
timeout
/* seconds */
);
DLLEXPORT
union
xp_sockaddr
*
inet_ptoaddr
(
char
*
addr_str
,
union
xp_sockaddr
*
addr
,
size_t
size
);
DLLEXPORT
union
xp_sockaddr
*
inet_ptoaddr
(
const
char
*
addr_str
,
union
xp_sockaddr
*
addr
,
size_t
size
);
DLLEXPORT
const
char
*
inet_addrtop
(
union
xp_sockaddr
*
addr
,
char
*
dest
,
size_t
size
);
DLLEXPORT
uint16_t
inet_addrport
(
union
xp_sockaddr
*
addr
);
DLLEXPORT
void
inet_setaddrport
(
union
xp_sockaddr
*
addr
,
uint16_t
port
);
...
...
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