diff options
| author | Dusan Durech <dusan@debian.debian> | 2009-03-01 18:09:11 +0100 |
|---|---|---|
| committer | Dusan Durech <dusan@debian.debian> | 2009-03-01 18:09:11 +0100 |
| commit | b21832e8d922351169ab4d06e7993ed401fe0924 (patch) | |
| tree | 882f8d3deb61ea8a4586a06c9c5cb5f2e8206054 /src/base/server.c | |
| parent | 0fe84801e04022b1c92de363ec907fa6dd63bfd2 (diff) | |
API to UDP and TCP has been modified so that they can be used independet from protocols IPv4 and IPv6
Diffstat (limited to 'src/base/server.c')
| -rw-r--r-- | src/base/server.c | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/src/base/server.c b/src/base/server.c index 2112927..6471b46 100644 --- a/src/base/server.c +++ b/src/base/server.c @@ -238,13 +238,21 @@ int initServer(char *ip4, int port4, char *ip6, int port6) setServerMaxClients(SERVER_MAX_CLIENTS); setServerTimer(); + //printf("%s %d %s %d\n", ip4, port4, ip6, port6); ret = initUdpServer(ip4, port4, ip6, port6); if (ret == 0) { return -1; } - initDownServer(ip4, port4); + if( ip4 != NULL ) + { + initDownServer(ip4, port4); + } + else if( ip6 != NULL ) + { + initDownServer(ip6, port6); + } return ret; } |