tests: Cleanup islower() warning.
authorJustin Pettit <jpettit@nicira.com>
Tue, 25 Aug 2009 23:33:16 +0000 (16:33 -0700)
committerJustin Pettit <jpettit@nicira.com>
Tue, 25 Aug 2009 23:37:28 +0000 (16:37 -0700)
NetBSD's gcc complains if islower()'s argument is an unadorned char.  This
provides an appropriate cast.

tests/test-stp.c

index c2a5837..ce9decc 100644 (file)
@@ -501,7 +501,8 @@ main(int argc, char *argv[])
 
                         if (!strcmp(token, "0")) {
                             lan = NULL;
-                        } else if (strlen(token) == 1 && islower(*token)) {
+                        } else if (strlen(token) == 1
+                                && islower((unsigned char)*token)) {
                             lan = tc->lans[*token - 'a']; 
                         } else {
                             err("%s is not a valid LAN name "