+/*
+ * New C++ configuration routines
+ */
+
+class CONFIG {
+public:
+ const char *m_cf; /* config file */
+ LEX_ERROR_HANDLER *m_scan_error; /* error handler if non-null */
+ int32_t m_err_type; /* the way to terminate on failure */
+ void *m_res_all; /* pointer to res_all buffer */
+ int32_t m_res_all_size; /* length of buffer */
+
+ /* The below are not yet implemented */
+ int32_t m_r_first; /* first daemon resource type */
+ int32_t m_r_last; /* last daemon resource type */
+ RES_TABLE *m_resources; /* pointer to table of permitted resources */
+ RES **m_res_head; /* pointer to defined resources */
+ brwlock_t m_res_lock; /* resource lock */
+
+ /* functions */
+ void init(
+ const char *cf,
+ LEX_ERROR_HANDLER *scan_error,
+ int32_t err_type,
+ void *vres_all,
+ int32_t res_all_size,
+ int32_t r_first,
+ int32_t r_last,
+ RES_TABLE *resources,
+ RES **res_head);
+
+ bool parse_config();
+ void free_resources();
+ RES **save_resources();
+ RES **new_res_head();
+};
+
+CONFIG *new_config_parser();