Author: sam
Date: Mon Dec 15 01:09:01 2008
New Revision: 186102
URL: http://svn.freebsd.org/changeset/base/186102

Log:
  0 is a potential ISO CC; use new NO_COUNTRY #define to identify
  when the CC is not set.  Note NO_COUNTRY is set to 0xffff for now
  (must be 16 bits as ieee80211_regdomain struct defines sku's and
  cc's as uint16_t which may need fixing).

Modified:
  head/sbin/ifconfig/ifieee80211.c

Modified: head/sbin/ifconfig/ifieee80211.c
==============================================================================
--- head/sbin/ifconfig/ifieee80211.c    Mon Dec 15 01:06:49 2008        
(r186101)
+++ head/sbin/ifconfig/ifieee80211.c    Mon Dec 15 01:09:01 2008        
(r186102)
@@ -425,7 +425,7 @@ setregdomain_cb(int s, void *arg)
        struct ieee80211_devcaps_req dc;
        struct regdata *rdp = getregdata();
 
-       if (rd->country != 0) {
+       if (rd->country != NO_COUNTRY) {
                const struct country *cc;
                /*
                 * Check current country seting to make sure it's
@@ -456,7 +456,7 @@ setregdomain_cb(int s, void *arg)
                                errx(1, "country %s (%s) is not usable with "
                                    "regdomain %d", cc->isoname, cc->name,
                                    rd->regdomain);
-                       else if (rp->cc != 0 && rp->cc != cc)
+                       else if (rp->cc != NULL && rp->cc != cc)
                                errx(1, "country %s (%s) is not usable with "
                                   "regdomain %s", cc->isoname, cc->name,
                                   rp->name);
_______________________________________________
[email protected] mailing list
http://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to "[email protected]"

Reply via email to