From: Ulrich Drepper Date: Fri, 30 Jan 1998 17:13:41 +0000 (+0000) Subject: (__nss_configure_lookup): Correct test for early exit of loop. X-Git-Tag: cvs/before-sparc-2_0_x-branch~252 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=ebc9ab8be40d3999c6d0c13b1339191de3c334b9;p=thirdparty%2Fglibc.git (__nss_configure_lookup): Correct test for early exit of loop. --- diff --git a/nss/nsswitch.c b/nss/nsswitch.c index 201a2bccfef..ac7cc877e6e 100644 --- a/nss/nsswitch.c +++ b/nss/nsswitch.c @@ -1,4 +1,4 @@ -/* Copyright (C) 1996, 1997 Free Software Foundation, Inc. +/* Copyright (C) 1996, 1997, 1998 Free Software Foundation, Inc. This file is part of the GNU C Library. Contributed by Ulrich Drepper , 1996. @@ -202,7 +202,7 @@ __nss_configure_lookup (const char *dbname, const char *service_line) int cmp = strcmp (dbname, databases[cnt].name); if (cmp == 0) break; - if (cmp > 0) + if (cmp < 0) { __set_errno (EINVAL); return -1;