aboutsummaryrefslogtreecommitdiff
path: root/src/common/config.h
diff options
context:
space:
mode:
authorBruce Montrose <montrose@itd.nrl.navy.mil>2002-07-03 16:31:22 +0000
committerBruce Montrose <montrose@itd.nrl.navy.mil>2002-07-03 16:31:22 +0000
commita3609f4d5d66ce4eeb4492422e7a0ec2d623a43a (patch)
treec1f5d2f144c45c1b3017b97f8bb3fcbe550e411f /src/common/config.h
parent419781685cc7fcccb18634cdd23b639ea73ba39f (diff)
downloadtor-a3609f4d5d66ce4eeb4492422e7a0ec2d623a43a.tar
tor-a3609f4d5d66ce4eeb4492422e7a0ec2d623a43a.tar.gz
Added getoptions() and made minor adjustment to poptReadDefaultOptions()
svn:r25
Diffstat (limited to 'src/common/config.h')
-rw-r--r--src/common/config.h15
1 files changed, 13 insertions, 2 deletions
diff --git a/src/common/config.h b/src/common/config.h
index 15d9b1e5d..7642086b1 100644
--- a/src/common/config.h
+++ b/src/common/config.h
@@ -8,8 +8,11 @@
/*
* Changes :
* $Log$
- * Revision 1.1 2002/06/26 22:45:50 arma
- * Initial revision
+ * Revision 1.2 2002/07/03 16:31:22 montrose
+ * Added getoptions() and made minor adjustment to poptReadDefaultOptions()
+ *
+ * Revision 1.1.1.1 2002/06/26 22:45:50 arma
+ * initial commit: current code
*
* Revision 1.7 2002/04/02 14:27:11 badbytes
* Final finishes.
@@ -39,6 +42,8 @@
# include <stdio.h>
+#include <popt.h>
+
/* enumeration of types which option values can take */
#define CONFIG_TYPE_STRING 0
#define CONFIG_TYPE_CHAR 1
@@ -84,5 +89,11 @@ int close_config(FILE *f);
/* parse the config file and obtain required option values */
int parse_config(FILE *f, config_opt_t *option);
+/* parse popt-style options in a config file */
+int poptReadOptions(poptContext optCon, const unsigned char *fname);
+
+/* parse popt-style options from /etc/<cmd>rc and ~/.<cmd>rc */
+int poptReadDefaultOptions(const char *cmd, poptContext optCon);
+
#define __CONFIG_H
#endif