projects
/
tinc
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Fix compiler warnings.
[tinc]
/
src
/
net_setup.c
diff --git
a/src/net_setup.c
b/src/net_setup.c
index
6d15fcf
..
96a7224
100644
(file)
--- a/
src/net_setup.c
+++ b/
src/net_setup.c
@@
-445,7
+445,6
@@
bool setup_myself_reloadable(void) {
char *fmode = NULL;
char *bmode = NULL;
char *afname = NULL;
char *fmode = NULL;
char *bmode = NULL;
char *afname = NULL;
- char *address = NULL;
char *space;
bool choice;
char *space;
bool choice;
@@
-1037,7
+1036,7
@@
static bool setup_myself(void) {
/* If no Port option was specified, set myport to the port used by the first listening socket. */
/* If no Port option was specified, set myport to the port used by the first listening socket. */
- if(!port_specified) {
+ if(!port_specified
|| atoi(myport) == 0
) {
sockaddr_t sa;
socklen_t salen = sizeof sa;
if(!getsockname(listen_socket[0].udp.fd, &sa.sa, &salen)) {
sockaddr_t sa;
socklen_t salen = sizeof sa;
if(!getsockname(listen_socket[0].udp.fd, &sa.sa, &salen)) {