]> granicus.if.org Git - sudo/commitdiff
Add NOMATCH and UNSPEC defines (-1 and -2 respectively) and use
authorTodd C. Miller <Todd.Miller@courtesan.com>
Sat, 5 Jun 2004 17:42:04 +0000 (17:42 +0000)
committerTodd C. Miller <Todd.Miller@courtesan.com>
Sat, 5 Jun 2004 17:42:04 +0000 (17:42 +0000)
these in parse.yacc.  Also in parse.yacc initialize the *_matches
vars to UNSPEC and add two macros, SETMATCH and SETNMATCH for use
when setting *_matches to a value that may be NOMATCH/UNSPEC/TRUE/FALSE.

sudo.h

diff --git a/sudo.h b/sudo.h
index 18b7736b89df7b253d8d38e0858dbad8de04b90c..2d21bccd2b54754b3b07ffe3dfd93ffec565fac7 100644 (file)
--- a/sudo.h
+++ b/sudo.h
@@ -65,12 +65,16 @@ struct sudo_user {
 #define FLAG_NOEXEC            0x200
 
 /*
- * Boolean values
+ * Pseudo-boolean values
  */
 #undef TRUE
 #define TRUE                     1
 #undef FALSE
 #define FALSE                    0
+#undef NOMATCH
+#define NOMATCH                 -1
+#undef UNSPEC
+#define UNSPEC                  -2
 
 /*
  * find_path()/load_cmnd() return values