Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/usr.sbin/config check the duplication or the inconsistency b...



details:   https://anonhg.NetBSD.org/src/rev/3d87401fd7d0
branches:  trunk
changeset: 542185:3d87401fd7d0
user:      gehenna <gehenna%NetBSD.org@localhost>
date:      Thu Jan 23 15:01:54 2003 +0000

description:
check the duplication or the inconsistency before evaluating fopts.

diffstat:

 usr.sbin/config/files.c |  10 +++++-----
 1 files changed, 5 insertions(+), 5 deletions(-)

diffs (31 lines):

diff -r 5571998726d0 -r 3d87401fd7d0 usr.sbin/config/files.c
--- a/usr.sbin/config/files.c   Thu Jan 23 14:58:07 2003 +0000
+++ b/usr.sbin/config/files.c   Thu Jan 23 15:01:54 2003 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: files.c,v 1.18 2003/01/23 14:57:40 gehenna Exp $       */
+/*     $NetBSD: files.c,v 1.19 2003/01/23 15:01:54 gehenna Exp $       */
 
 /*
  * Copyright (c) 1992, 1993
@@ -339,10 +339,6 @@
        fixdevmtab = ht_new();
 
        TAILQ_FOREACH(dm, &alldevms, dm_next) {
-               if (dm->dm_opts != NULL &&
-                   !expr_eval(dm->dm_opts, fixsel, NULL))
-                       continue;
-
                res = ht_lookup(fixdevmtab, intern(dm->dm_name));
                if (res != NULL) {
                        if (res->dm_cmajor != dm->dm_cmajor ||
@@ -372,6 +368,10 @@
                        }
                }
 
+               if (dm->dm_opts != NULL &&
+                   !expr_eval(dm->dm_opts, fixsel, NULL))
+                       continue;
+
                if (ht_lookup(cdevmtab, intern(dm->dm_name)) != NULL) {
                        xerror(dm->dm_srcfile, dm->dm_srcline,
                               "device-major of character device '%s' is "



Home | Main Index | Thread Index | Old Index