about summary refs log tree commit diff
path: root/nis/nis_findserv.c
diff options
context:
space:
mode:
Diffstat (limited to 'nis/nis_findserv.c')
-rw-r--r--nis/nis_findserv.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/nis/nis_findserv.c b/nis/nis_findserv.c
index 0e9f01700d..832b6a541d 100644
--- a/nis/nis_findserv.c
+++ b/nis/nis_findserv.c
@@ -138,7 +138,7 @@ __nis_findfastest (dir_binding * bind)
       if (strcmp (bind->server_val[i].ep.ep_val[j].family, "inet") == 0)
 	if ((bind->server_val[i].ep.ep_val[j].proto == NULL) ||
 	    (strcmp (bind->server_val[i].ep.ep_val[j].proto, "-") == 0) ||
-	    (strlen (bind->server_val[i].ep.ep_val[j].proto) == 0))
+	    (bind->server_val[i].ep.ep_val[j].proto[0] == '\0'))
 	  {
 	    sin.sin_addr.s_addr =
 	      inetstr2int (bind->server_val[i].ep.ep_val[j].uaddr);