From e7c6a1c7f9170ec0d3c1c4581d1afc9984bcf733 Mon Sep 17 00:00:00 2001 From: Fumitoshi UKAI Date: Thu, 10 Jan 2002 15:39:21 +0000 Subject: [w3m-dev 02815] From: aito@fw.ipsj.or.jp --- url.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'url.c') diff --git a/url.c b/url.c index 28f5472..446cf44 100644 --- a/url.c +++ b/url.c @@ -1,4 +1,4 @@ -/* $Id: url.c,v 1.29 2002/01/07 16:28:17 ukai Exp $ */ +/* $Id: url.c,v 1.30 2002/01/10 15:39:21 ukai Exp $ */ #include "fm.h" #include #include @@ -626,8 +626,8 @@ openSocket(char *const hostname, #endif goto error; } - regexCompile("^[0-9][0-9]*\\.[0-9][0-9]*\\.[0-9][0-9]*\\.[0-9][0-9]*$", 0); - if (regexMatch(hostname, 0, 1)) { + regexCompile("^[0-9]+\\.[0-9]+\\.[0-9]+\\.[0-9]+$", 0); + if (regexMatch(hostname, -1, 1)) { sscanf(hostname, "%d.%d.%d.%d", &a1, &a2, &a3, &a4); adr = htonl((a1 << 24) | (a2 << 16) | (a3 << 8) | a4); bcopy((void *)&adr, (void *)&hostaddr.sin_addr, sizeof(long)); -- cgit v1.2.3