r25355: IP address parsing did not allow for fully expanded ipv6 addresses
authorSteve French <sfrench@samba.org>
Wed, 26 Sep 2007 18:36:38 +0000 (18:36 +0000)
committerGerald (Jerry) Carter <jerry@samba.org>
Wed, 10 Oct 2007 17:31:00 +0000 (12:31 -0500)
(which can be 12 bytes longer than we were allowing for).

Thanks to Dr. David Holder

source/client/mount.cifs.c

index eb45ae5b4a038ed2ff76a4bce6fd09971e50c1b6..5ed0f27ab1e66e991812aa67cf83f594042100df 100755 (executable)
@@ -426,7 +426,7 @@ static int parse_options(char ** optionsp, int * filesys_flags)
                } else if (strncmp(data, "ip", 2) == 0) {
                        if (!value || !*value) {
                                printf("target ip address argument missing");
-                       } else if (strnlen(value, 35) < 35) {
+                       } else if (strnlen(value, INET6_ADDRSTRLEN) < INET6_ADDRSTRLEN) {
                                if(verboseflag)
                                        printf("ip address %s override specified\n",value);
                                got_ip = 1;