X-Git-Url: https://git.verplant.org/?a=blobdiff_plain;f=src%2Frrd_client.c;h=a4f1ba9c86fd8022db488da266547af6b8fba4f9;hb=921d0fc99df63031b0d183c82f510e6e97f24a30;hp=287f642db4754253eba0134679bf1e650f60ad45;hpb=6f5e93c0c08c5ed796d8d079f0eba2d16c6a4bdb;p=rrdtool.git diff --git a/src/rrd_client.c b/src/rrd_client.c index 287f642..a4f1ba9 100644 --- a/src/rrd_client.c +++ b/src/rrd_client.c @@ -436,8 +436,8 @@ static int rrdc_connect_network (const char *addr_orig) /* {{{ */ rrd_set_error("garbage after address: %s", port); return (-1); } - } /* if (*addr = ']') */ - else if (strchr (addr, '.') != NULL) /* Hostname or IPv4 */ + } /* if (*addr == '[') */ + else { port = rindex(addr, ':'); if (port != NULL)