"First thing, kill all the language lawyers" :-). Ensure possible insane compilers
authorJeremy Allison <jra@samba.org>
Fri, 16 Jan 2009 19:55:01 +0000 (11:55 -0800)
committerJeremy Allison <jra@samba.org>
Fri, 16 Jan 2009 19:55:01 +0000 (11:55 -0800)
can't kill us later.
Jeremy.

source3/lib/util_sock.c

index b46ff2c..98c25c1 100644 (file)
@@ -1889,6 +1889,7 @@ const char *get_mydnsfullname(void)
 bool is_myname_or_ipaddr(const char *s)
 {
        TALLOC_CTX *ctx = talloc_tos();
+       char addr[INET6_ADDRSTRLEN];
        char *name = NULL;
        const char *dnsname;
        char *servername = NULL;
@@ -1941,7 +1942,6 @@ bool is_myname_or_ipaddr(const char *s)
                /* Use DNS to resolve the name, but only the first address */
                struct sockaddr_storage ss;
                if (interpret_string_addr(&ss, servername, 0)) {
-                       char addr[INET6_ADDRSTRLEN];
                        print_sockaddr(addr,
                                        sizeof(addr),
                                        &ss);