~mdw
/
become
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Support no-network configuration option, and new interface to
[become]
/
src
/
check.c
diff --git
a/src/check.c
b/src/check.c
index
1a7d507
..
a2d13b5
100644
(file)
--- a/
src/check.c
+++ b/
src/check.c
@@
-1,6
+1,6
@@
/* -*-c-*-
*
/* -*-c-*-
*
- * $Id: check.c,v 1.
6 1998/01/12 16:45:47
mdw Exp $
+ * $Id: check.c,v 1.
7 1998/04/23 13:22:08
mdw Exp $
*
* Check validity of requests
*
*
* Check validity of requests
*
@@
-29,6
+29,10
@@
/*----- Revision history --------------------------------------------------*
*
* $Log: check.c,v $
/*----- Revision history --------------------------------------------------*
*
* $Log: check.c,v $
+ * Revision 1.7 1998/04/23 13:22:08 mdw
+ * Support no-network configuration option, and new interface to
+ * configuration file parser.
+ *
* Revision 1.6 1998/01/12 16:45:47 mdw
* Fix copyright date.
*
* Revision 1.6 1998/01/12 16:45:47 mdw
* Fix copyright date.
*
@@
-91,7
+95,9
@@
#include "userdb.h"
#include "utils.h"
#include "userdb.h"
#include "utils.h"
-/*----- Main code ---------------------------------------------------------*/
+/*----- Client-end network support ----------------------------------------*/
+
+#ifndef NONETWORK
/* --- @check__send@ --- *
*
/* --- @check__send@ --- *
*
@@
-509,6
+515,10
@@
int check__client(request *rq, FILE *fp)
return (check__ask(rq, serv, n_serv));
}
return (check__ask(rq, serv, n_serv));
}
+#endif
+
+/*----- Main checking function --------------------------------------------*/
+
/* --- @check@ --- *
*
* Arguments: @request *rq@ = pointer to request buffer
/* --- @check@ --- *
*
* Arguments: @request *rq@ = pointer to request buffer
@@
-524,8
+534,10
@@
int check(request *rq)
/* --- Check if we need to talk to a server --- */
/* --- Check if we need to talk to a server --- */
+#ifndef NONETWORK
if ((fp = fopen(file_SERVER, "r")) != 0)
return (check__client(rq, fp));
if ((fp = fopen(file_SERVER, "r")) != 0)
return (check__client(rq, fp));
+#endif
/* --- Otherwise do this all the old-fashioned way --- */
/* --- Otherwise do this all the old-fashioned way --- */
@@
-541,7
+553,7
@@
int check(request *rq)
name_init();
rule_init();
lexer_scan(fp);
name_init();
rule_init();
lexer_scan(fp);
-
yy
parse();
+ parse();
return (rule_check(rq));
}
return (rule_check(rq));
}