summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorSergey Poznyakoff <gray@gnu.org.ua>2016-10-19 17:20:42 +0300
committerSergey Poznyakoff <gray@gnu.org.ua>2016-10-19 19:20:31 +0300
commitdc78d43ff77a65e3400af0401142aca2ebb6cd1e (patch)
tree61b7442d72109e743527a19e5e4ae575a749ed2d /include
parentd1339b3ffaa3d82e21c3a36e5bdfccee3246904d (diff)
downloadmailutils-dc78d43ff77a65e3400af0401142aca2ebb6cd1e.tar.gz
mailutils-dc78d43ff77a65e3400af0401142aca2ebb6cd1e.tar.bz2
Convert remaining utilities (except mh) to mu_cli.
* Makefile.am: Remove libmu_argp and libmu_cfg * configure.ac: Likewise. * libmu_argp/: Remove. * libmu_cfg/: Remove. * include/mailutils/Makefile.am (pkginclude_HEADERS): Remove gocs.h, libargp.h, libcfg.h * frm/frm.c: Register tls auth module * frm/from.c: Likewise. * maidag/maidag.c: Likewise. * mail/mail.c: Likewise. * messages/messages.c: Likewise. * movemail/movemail.c: Likewise. * readmsg/readmsg.c: Likewise. * sieve/sieve.c: Likewise. * frm/frm.h: Remove obsolete includes * imap4d/Makefile.am: Update. * imap4d/imap4d.c: Use mu_cli for command line and configuration parsing. * imap4d/imap4d.h: Update. * include/mailutils/gocs.h: Remove. * libmailutils/cfg/gocs.c: Remove. * libmailutils/cfg/Makefile.am: Remove gocs.c * include/mailutils/cli.h (mu_cli_capa_apply): Rename to mu_cli_capa_extend_settings (mu_cli_setup) <inorder, prog_doc_hook>: New fields. * include/mailutils/daemon.h: Remove obsolete includes. * include/mailutils/gsasl.h: Likewise. * include/mailutils/mailutils.h: Update. * include/mailutils/mu_auth.h (mu_auth_mode): New enum (mu_auth_module): Redo structure. * include/mailutils/opt.h (mu_parseopt) <po_prog_doc_hook>: New field. * include/mailutils/sql.h (mu_sql_module_config): New extern. (mu_sql_interface_index): Change proto. * libmailutils/auth/mu_auth.c: Rewrite. * libmailutils/auth/system.c (mu_auth_system_module): Update structure * libmailutils/cli/capa.c (mu_cli_capa_apply): Rename to mu_cli_capa_extend_settings * libmailutils/cli/cli.c: Extend settings from auth modules as well. * libmailutils/opt/help.c (mu_program_help): Invoke po_prog_doc_hook if defined. * libmailutils/opt/opt.c (parseopt_init): Check the MU_PARSEOPT_PROG_DOC_HOOK flag. (find_long_option): Fix recognition of ambiguous options in case of exact match. * libmu_auth/gsasl.c: Add configuration. * libmu_auth/ldap.c: Likewise. * libmu_auth/pam.c: Likewise. * libmu_auth/radius.c: Likewise. * libmu_auth/sql.c: Likewise. * libmu_auth/tls.c: Likewise. * libmu_auth/virtual.c: Likewise. * mu/Makefile.am: Update. * mu/mu.c: Rewrite using mu_cli * mu/mu.h: Likewise. * mu/acl.c: Likewise. * mu/cflags.c: Likewise. * mu/dbm.c: Likewise. * mu/dispatch.c: Likewise. * mu/filter.c: Likewise. * mu/flt2047.c: Likewise. * mu/getans.c: Likewise. * mu/getarg.c: Likewise. * mu/getyn.c: Likewise. * mu/help.c: Likewise. * mu/imap.c: Likewise. * mu/info.c: Likewise. * mu/ldflags.c: Likewise. * mu/logger.c: Likewise. * mu/pop.c: Likewise. * mu/query.c: Likewise. * mu/send.c: Likewise. * mu/shell.c: Likewise. * mu/smtp.c: Likewise. * mu/util.c: Likewise. * mu/verbose.c: Likewise. * mu/wicket.c: Likewise. * pop3d/Makefile.am: Update. * pop3d/pop3d.c: Convert to mu_cli interface. * pop3d/pop3d.h: Likewise. * sql/sql.c (mu_sql_interface_index): Change argument qualifiers.
Diffstat (limited to 'include')
-rw-r--r--include/mailutils/Makefile.am3
-rw-r--r--include/mailutils/cli.h5
-rw-r--r--include/mailutils/daemon.h3
-rw-r--r--include/mailutils/gocs.h98
-rw-r--r--include/mailutils/gsasl.h6
-rw-r--r--include/mailutils/libargp.h97
-rw-r--r--include/mailutils/libcfg.h101
-rw-r--r--include/mailutils/mailutils.h2
-rw-r--r--include/mailutils/mu_auth.h42
-rw-r--r--include/mailutils/opt.h2
-rw-r--r--include/mailutils/radius.h2
-rw-r--r--include/mailutils/sieve.h11
-rw-r--r--include/mailutils/sql.h22
-rw-r--r--include/mailutils/tls.h2
-rw-r--r--include/mailutils/types.hin6
15 files changed, 39 insertions, 363 deletions
diff --git a/include/mailutils/Makefile.am b/include/mailutils/Makefile.am
index 9ae3929af..d1e001904 100644
--- a/include/mailutils/Makefile.am
+++ b/include/mailutils/Makefile.am
@@ -48,7 +48,6 @@ pkginclude_HEADERS = \
error.h\
filter.h\
folder.h\
- gocs.h\
gsasl.h\
guile.h\
header.h\
@@ -59,8 +58,6 @@ pkginclude_HEADERS = \
iterator.h\
kwd.h\
ldap.h\
- libargp.h\
- libcfg.h\
list.h\
locker.h\
log.h\
diff --git a/include/mailutils/cli.h b/include/mailutils/cli.h
index 7067f213c..d2964ff1d 100644
--- a/include/mailutils/cli.h
+++ b/include/mailutils/cli.h
@@ -35,7 +35,8 @@ struct mu_cli_capa
void mu_cli_capa_init (void);
void mu_cli_capa_register (struct mu_cli_capa *capa);
-void mu_cli_capa_apply (char const *name, mu_list_t opts, mu_list_t commits);
+void mu_cli_capa_extend_settings (char const *name, mu_list_t opts,
+ mu_list_t commits);
struct mu_cli_setup
{
@@ -49,6 +50,8 @@ struct mu_cli_setup
int ex_usage; /* If not 0, exit code on usage errors */
int ex_config; /* If not 0, exit code on configuration
errors */
+ int inorder;
+ void (*prog_doc_hook) (mu_stream_t);
};
void mu_version_func (struct mu_parseopt *po, mu_stream_t stream);
diff --git a/include/mailutils/daemon.h b/include/mailutils/daemon.h
index fa29b41c7..2fa699e20 100644
--- a/include/mailutils/daemon.h
+++ b/include/mailutils/daemon.h
@@ -20,7 +20,6 @@
#define _MAILUTILS_DAEMON_H
#include <mailutils/types.h>
-#include <mailutils/gocs.h>
#ifdef __cplusplus
extern "C" {
@@ -33,8 +32,6 @@ extern "C" {
extern int mu_daemon_create_pidfile (const char *);
extern void mu_daemon_remove_pidfile (void);
-extern struct mu_gocs_daemon mu_gocs_daemon;
-
#ifdef __cplusplus
}
#endif
diff --git a/include/mailutils/gocs.h b/include/mailutils/gocs.h
deleted file mode 100644
index be3de555f..000000000
--- a/include/mailutils/gocs.h
+++ /dev/null
@@ -1,98 +0,0 @@
-/* GNU Mailutils -- a suite of utilities for electronic mail
- Copyright (C) 2007-2008, 2010-2012, 2014-2016 Free Software
- Foundation, Inc.
-
- This library is free software; you can redistribute it and/or
- modify it under the terms of the GNU Lesser General Public
- License as published by the Free Software Foundation; either
- version 3 of the License, or (at your option) any later version.
-
- This library is distributed in the hope that it will be useful,
- but WITHOUT ANY WARRANTY; without even the implied warranty of
- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- Lesser General Public License for more details.
-
- You should have received a copy of the GNU Lesser General
- Public License along with this library. If not, see
- <http://www.gnu.org/licenses/>. */
-
-#ifndef _MAILUTILS_GOCS_H
-#define _MAILUTILS_GOCS_H
-
-#include <mailutils/types.h>
-#include <mailutils/list.h>
-#include <mailutils/syslog.h>
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-struct mu_gocs_debug
-{
- char *string;
- int line_info;
-};
-
-struct mu_gocs_mailbox
-{
- char *mail_spool;
- char *mailbox_pattern;
- char *mailbox_type;
-};
-
-struct mu_gocs_locking
-{
- char *lock_flags;
- unsigned long lock_retry_timeout;
- unsigned long lock_retry_count;
- unsigned long lock_expire_timeout;
- char *external_locker;
-};
-
-struct mu_gocs_source_email
-{
- char *address;
- char *domain;
-};
-
-struct mu_gocs_mailer
-{
- char *mailer;
-};
-
-struct mu_gocs_pam
-{
- char *service;
-};
-
-struct mu_gocs_virtual
-{
- char *pwddir;
-};
-
-/* Auxiliary variables for use by libargp/libcfg */
-extern char *mu_site_rcfile;
-extern int mu_load_user_rcfile;
-extern int mu_load_site_rcfile;
-extern char *mu_load_rcfile;
-
-typedef int (*mu_gocs_init_fp) (enum mu_gocs_op op, void *data);
-
-void mu_gocs_register (const char *capa, mu_gocs_init_fp init);
-void mu_gocs_register_std (const char *name);
-void mu_gocs_store (char *capa, void *data);
-void mu_gocs_flush (void);
-int mu_gocs_enumerate (mu_list_action_t action, void *data);
-
-int mu_gocs_mailbox_init (enum mu_gocs_op, void *data);
-int mu_gocs_locking_init (enum mu_gocs_op, void *data);
-int mu_gocs_source_email_init (enum mu_gocs_op, void *data);
-int mu_gocs_mailer_init (enum mu_gocs_op, void *data);
-int mu_gocs_logging_init (enum mu_gocs_op, void *data);
-int mu_gocs_debug_init (enum mu_gocs_op, void *data);
-
-#ifdef __cplusplus
-}
-#endif
-
-#endif
diff --git a/include/mailutils/gsasl.h b/include/mailutils/gsasl.h
index ba61370ac..c9e3a6a2b 100644
--- a/include/mailutils/gsasl.h
+++ b/include/mailutils/gsasl.h
@@ -18,6 +18,7 @@
#ifndef _MAILUTILS_GSASL_H
#define _MAILUTILS_GSASL_H
+#include <mailutils/cli.h>
struct mu_gsasl_module_data
{
@@ -28,16 +29,13 @@ struct mu_gsasl_module_data
char *anon_user;
char *cram_md5_pwd;
};
+extern struct mu_gsasl_module_data mu_gsasl_module_data;
int mu_gsasl_enabled (void);
#ifdef WITH_GSASL
#include <gsasl.h>
-int mu_gsasl_module_init (enum mu_gocs_op, void *);
-extern struct mu_gsasl_module_data mu_gsasl_module_data;
-
-
int gsasl_encoder_stream (mu_stream_t *pstr, mu_stream_t transport,
Gsasl_session *ctx, int flags);
int gsasl_decoder_stream (mu_stream_t *pstr, mu_stream_t transport,
diff --git a/include/mailutils/libargp.h b/include/mailutils/libargp.h
deleted file mode 100644
index c2ef99284..000000000
--- a/include/mailutils/libargp.h
+++ /dev/null
@@ -1,97 +0,0 @@
-/* GNU Mailutils -- a suite of utilities for electronic mail
- Copyright (C) 1999-2001, 2004-2005, 2007-2008, 2010-2012, 2014-2016
- Free Software Foundation, Inc.
-
- This library is free software; you can redistribute it and/or
- modify it under the terms of the GNU Lesser General Public
- License as published by the Free Software Foundation; either
- version 3 of the License, or (at your option) any later version.
-
- This library is distributed in the hope that it will be useful,
- but WITHOUT ANY WARRANTY; without even the implied warranty of
- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- Lesser General Public License for more details.
-
- You should have received a copy of the GNU Lesser General
- Public License along with this library. If not, see
- <http://www.gnu.org/licenses/>. */
-
-#ifndef _MAILUTILS_LIBARGP_H
-#define _MAILUTILS_LIBARGP_H
-
-#include "mailutils/types.h"
-#include "mailutils/gocs.h"
-#include "mailutils/nls.h"
-#include "mailutils/error.h"
-#include "mailutils/errno.h"
-#include "mailutils/version.h"
-#include "argp.h"
-#include "errno.h"
-#include "strings.h"
-
-#include "mailutils/libcfg.h"
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-struct mu_cmdline_capa
-{
- char *name;
- struct argp_child *child;
- void (*modflags) (int *);
-};
-
-extern int mu_help_config_mode;
-extern int mu_rcfile_lint;
-extern int (*mu_app_cfg_verifier) (void);
-
-extern struct mu_cmdline_capa mu_mailutils_cmdline;
-extern struct mu_cmdline_capa mu_common_cmdline;
-extern struct mu_cmdline_capa mu_logging_cmdline;
-extern struct mu_cmdline_capa mu_mailbox_cmdline;
-extern struct mu_cmdline_capa mu_locking_cmdline;
-extern struct mu_cmdline_capa mu_address_cmdline;
-extern struct mu_cmdline_capa mu_mailer_cmdline;
-extern struct mu_cmdline_capa mu_sieve_cmdline;
-extern struct mu_cmdline_capa mu_debug_cmdline;
-
-extern struct mu_cmdline_capa mu_pam_cmdline;
-extern struct mu_cmdline_capa mu_gsasl_cmdline;
-extern struct mu_cmdline_capa mu_radius_cmdline;
-extern struct mu_cmdline_capa mu_sql_cmdline;
-extern struct mu_cmdline_capa mu_virtdomain_cmdline;
-
-extern void mu_libargp_init (void);
-
-extern struct argp *mu_argp_build (const struct argp *argp, char ***pcapa,
- int *flags);
-extern void mu_argp_done (struct argp *argp);
-
-extern int mu_register_argp_capa (const char *name, struct argp_child *child,
- void (*modflags) (int*));
-
-void mu_argp_init (const char *vers, const char *bugaddr);
-int mu_app_init (struct argp *myargp, const char **capa,
- struct mu_cfg_param *cfg_param,
- int argc, char **argv, int flags, int *pindex, void *data);
-extern void mu_program_version_hook (FILE *stream, struct argp_state *state);
-
-error_t mu_argp_parse (const struct argp *myargp,
- int *pargc, char **pargv[],
- unsigned flags,
- const char *capa[],
- int *arg_index,
- void *input) MU_DEPRECATED;
-
-void mu_argp_node_list_init (mu_list_t *);
-void mu_argp_node_list_add (mu_list_t, mu_cfg_node_t *);
-void mu_argp_node_list_new (mu_list_t, const char *, const char *);
-void mu_argp_node_list_finish (mu_list_t, char *, char *);
-
-#ifdef __cplusplus
-}
-#endif
-
-#endif
-
diff --git a/include/mailutils/libcfg.h b/include/mailutils/libcfg.h
deleted file mode 100644
index c7730ad04..000000000
--- a/include/mailutils/libcfg.h
+++ /dev/null
@@ -1,101 +0,0 @@
-/* GNU Mailutils -- a suite of utilities for electronic mail
- Copyright (C) 2007-2012, 2014-2016 Free Software Foundation, Inc.
-
- This library is free software; you can redistribute it and/or
- modify it under the terms of the GNU Lesser General Public
- License as published by the Free Software Foundation; either
- version 3 of the License, or (at your option) any later version.
-
- This library is distributed in the hope that it will be useful,
- but WITHOUT ANY WARRANTY; without even the implied warranty of
- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- Lesser General Public License for more details.
-
- You should have received a copy of the GNU Lesser General
- Public License along with this library. If not, see
- <http://www.gnu.org/licenses/>. */
-
-#ifndef _MAILUTILS_LIBCFG_H
-#define _MAILUTILS_LIBCFG_H
-
-#include <mailutils/cfg.h>
-#include <mailutils/gocs.h>
-#include <mailutils/nls.h>
-#include <mailutils/error.h>
-#include <mailutils/errno.h>
-
-#ifndef MU_USER_CONFIG_FILE
-# define MU_USER_CONFIG_FILE "~/.mailutils"
-#endif
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-struct mu_cfg_capa
-{
- char *name;
- struct mu_cfg_param *cfgparam;
- mu_cfg_section_fp parser;
-};
-
-extern int mu_libcfg_register_capa (struct mu_cfg_capa *capa);
-extern void mu_libcfg_init (char **cnames);
-extern int mu_parse_config_files (struct mu_cfg_param *param,
- void *target_ptr) MU_CFG_DEPRECATED;
-int mu_libcfg_parse_config (mu_cfg_tree_t **ptree);
-
-extern void mu_acl_cfg_init (void);
-
-#define __mu_common_cat2__(a,b) a ## b
-#define __mu_common_cat3__(a,b,c) a ## b ## c
-#define DCL_PARSER(capa) \
-int \
-__mu_common_cat3__(mu_,capa,_section_parser) \
- (enum mu_cfg_section_stage stage, const mu_cfg_node_t *node, \
- const char *section_label, void **section_data, \
- void *call_data, mu_cfg_tree_t *tree) \
-{ \
- switch (stage) \
- { \
- case mu_cfg_section_start: \
- break; \
- \
- case mu_cfg_section_end: \
- mu_gocs_store (#capa, &__mu_common_cat2__(capa, _settings)); \
- } \
- return 0; \
-}
-
-#define DCL_DEFAULT_CFG_CAPA(capa) \
- struct mu_cfg_capa __mu_common_cat3__(mu_,capa,_cfg_capa) = { \
- #capa, \
- __mu_common_cat3__(mu_,capa,_param), \
- __mu_common_cat3__(mu_,capa,_section_parser) \
- }
-
-#define DCL_CFG_CAPA(capa) \
- DCL_PARSER (capa) \
- DCL_DEFAULT_CFG_CAPA (capa)
-
-extern struct mu_cfg_capa mu_mailbox_cfg_capa;
-extern struct mu_cfg_capa mu_locking_cfg_capa;
-extern struct mu_cfg_capa mu_address_cfg_capa;
-extern struct mu_cfg_capa mu_mailer_cfg_capa;
-extern struct mu_cfg_capa mu_logging_cfg_capa;
-extern struct mu_cfg_capa mu_debug_cfg_capa;
-extern struct mu_cfg_capa mu_gsasl_cfg_capa;
-extern struct mu_cfg_capa mu_pam_cfg_capa;
-extern struct mu_cfg_capa mu_radius_cfg_capa;
-extern struct mu_cfg_capa mu_sql_cfg_capa;
-extern struct mu_cfg_capa mu_tls_cfg_capa;
-extern struct mu_cfg_capa mu_virtdomain_cfg_capa;
-extern struct mu_cfg_capa mu_sieve_cfg_capa;
-extern struct mu_cfg_capa mu_auth_cfg_capa;
-extern struct mu_cfg_capa mu_ldap_cfg_capa;
-
-#ifdef __cplusplus
-}
-#endif
-
-#endif
diff --git a/include/mailutils/mailutils.h b/include/mailutils/mailutils.h
index 5ed71d29c..cc14889fb 100644
--- a/include/mailutils/mailutils.h
+++ b/include/mailutils/mailutils.h
@@ -58,7 +58,6 @@
#include <mailutils/stream.h>
#include <mailutils/tls.h>
#include <mailutils/url.h>
-#include <mailutils/gocs.h>
#include <mailutils/version.h>
#include <mailutils/io.h>
#include <mailutils/secret.h>
@@ -66,6 +65,7 @@
#include <mailutils/cstr.h>
#include <mailutils/wordsplit.h>
#include <mailutils/log.h>
+#include <mailutils/syslog.h>
#include <mailutils/stdstream.h>
#include <mailutils/prog.h>
#include <mailutils/sockaddr.h>
diff --git a/include/mailutils/mu_auth.h b/include/mailutils/mu_auth.h
index 4355d9315..a67cc61fb 100644
--- a/include/mailutils/mu_auth.h
+++ b/include/mailutils/mu_auth.h
@@ -20,8 +20,8 @@
#define _MAILUTILS_MU_AUTH_H
#include <mailutils/types.h>
-#include <mailutils/gocs.h>
#include <mailutils/debug.h>
+#include <mailutils/cli.h>
#define MU_AUTH_NAME "name"
#define MU_AUTH_PASSWD "passwd"
@@ -64,30 +64,41 @@ typedef int (*mu_auth_fp) (struct mu_auth_data **data,
void *func_data,
void *call_data);
+enum mu_auth_mode
+ {
+ mu_auth_authenticate,
+ mu_auth_getpwnam,
+ mu_auth_getpwuid
+ };
+
+#define MU_AUTH_MODE_COUNT 3
+
struct mu_auth_module
{
char *name;
- mu_gocs_init_fp init;
- mu_auth_fp authenticate;
- void *authenticate_data;
- mu_auth_fp auth_by_name;
- void *auth_by_name_data;
- mu_auth_fp auth_by_uid;
- void *auth_by_uid_data;
+ mu_auth_fp handler[MU_AUTH_MODE_COUNT];
+ void *data[MU_AUTH_MODE_COUNT];
+
+ struct mu_option *opt;
+ struct mu_cfg_param *cfg;
+ mu_cfg_section_fp parser;
+ mu_cli_capa_commit_fp commit;
};
enum mu_auth_key_type
{
- mu_auth_key_name,
- mu_auth_key_uid
+ mu_auth_key_name = mu_auth_getpwnam,
+ mu_auth_key_uid = mu_auth_getpwuid
};
void mu_auth_begin_setup (void);
void mu_auth_finish_setup (void);
+void mu_auth_extend_settings (mu_list_t opts, mu_list_t commits);
-extern int mu_auth_runlist (mu_list_t flist,
- struct mu_auth_data **return_data,
- const void *key, void *data);
+int mu_auth_runlist (mu_list_t flist,
+ enum mu_auth_mode mode,
+ const void *key, void *data,
+ struct mu_auth_data **return_data);
extern int mu_get_auth (struct mu_auth_data **auth, enum mu_auth_key_type type,
const void *key);
@@ -116,7 +127,6 @@ extern void mu_authentication_add_module_list (const char *modlist);
extern void mu_authentication_clear_list (void);
extern void mu_authorization_clear_list (void);
-extern void mu_auth_init (void);
extern int mu_auth_data_alloc (struct mu_auth_data **ptr,
const char *name,
const char *passwd,
@@ -138,6 +148,8 @@ extern struct mu_auth_module mu_auth_sql_module;
extern struct mu_auth_module mu_auth_virtual_module;
extern struct mu_auth_module mu_auth_radius_module;
extern struct mu_auth_module mu_auth_ldap_module;
+extern struct mu_auth_module mu_auth_gsasl_module;
+extern struct mu_auth_module mu_auth_tls_module;
#define MU_AUTH_REGISTER_ALL_MODULES() do {\
mu_auth_register_module (&mu_auth_generic_module); \
@@ -147,6 +159,8 @@ extern struct mu_auth_module mu_auth_ldap_module;
mu_auth_register_module (&mu_auth_virtual_module);\
mu_auth_register_module (&mu_auth_radius_module);\
mu_auth_register_module (&mu_auth_ldap_module);\
+ mu_auth_register_module (&mu_auth_gsasl_module);\
+ mu_auth_register_module (&mu_auth_tls_module);\
} while (0)
#endif
diff --git a/include/mailutils/opt.h b/include/mailutils/opt.h
index 87a983937..fc4082497 100644
--- a/include/mailutils/opt.h
+++ b/include/mailutils/opt.h
@@ -102,6 +102,7 @@ struct mu_option_cache
#define MU_PARSEOPT_HELP_HOOK 0x00200000
#define MU_PARSEOPT_DATA 0x00400000
#define MU_PARSEOPT_VERSION_HOOK 0x00800000
+#define MU_PARSEOPT_PROG_DOC_HOOK 0x01000000
/* Reuse mu_parseopt struct initialized previously */
#define MU_PARSEOPT_REUSE 0x80000000
@@ -131,6 +132,7 @@ struct mu_parseopt
char const *po_package_url;
char const *po_extra_info;
+ void (*po_prog_doc_hook) (struct mu_parseopt *po, mu_stream_t stream);
void (*po_help_hook) (struct mu_parseopt *po, mu_stream_t stream);
void (*po_version_hook) (struct mu_parseopt *po, mu_stream_t stream);
diff --git a/include/mailutils/radius.h b/include/mailutils/radius.h
index 2fe70b2ff..67d39ff5d 100644
--- a/include/mailutils/radius.h
+++ b/include/mailutils/radius.h
@@ -28,6 +28,4 @@ struct mu_radius_module_data
char *getpwuid_request;
};
-extern int mu_radius_module_init (enum mu_gocs_op, void *data);
-
#endif
diff --git a/include/mailutils/sieve.h b/include/mailutils/sieve.h
index 1ba1a7279..9aab6c6eb 100644
--- a/include/mailutils/sieve.h
+++ b/include/mailutils/sieve.h
@@ -272,17 +272,6 @@ int mu_sieve_disass (mu_sieve_machine_t mach);
#define MU_SIEVE_CLEAR_INCLUDE_PATH 0x1
#define MU_SIEVE_CLEAR_LIBRARY_PATH 0x2
-struct mu_gocs_sieve
-{
- int clearflags;
- /* mu_list_t include_path_prefix;*/
- mu_list_t include_path;
- mu_list_t library_path_prefix;
- mu_list_t library_path;
-};
-
-int mu_sieve_module_init (enum mu_gocs_op, void *);
-
extern struct mu_cli_capa mu_cli_capa_sieve;
#ifdef __cplusplus
diff --git a/include/mailutils/sql.h b/include/mailutils/sql.h
index e08f49b89..ff3a16ebc 100644
--- a/include/mailutils/sql.h
+++ b/include/mailutils/sql.h
@@ -29,24 +29,6 @@ enum mu_password_type
struct mu_sql_module_config
{
- char *interface;
- char *getpwnam_query;
- char *getpass_query;
- char *getpwuid_query;
- char *host;
- char *user;
- char *passwd;
- char *db;
- int port;
- enum mu_password_type password_type;
- int positional;
- mu_assoc_t field_map;
-};
-
-/* FIXME: Should not be here, but needed for several other sources
- (imap4d/auth_gsasl.c, for instance) */
-struct mu_internal_sql_config
-{
int interface;
char *getpwnam_query;
char *getpass_query;
@@ -61,7 +43,7 @@ struct mu_internal_sql_config
mu_assoc_t field_map;
};
-extern struct mu_internal_sql_config mu_sql_module_config;
+extern struct mu_sql_module_config mu_sql_module_config;
/* Loadable Modules Support */
#define __s_cat2__(a,b) a ## b
@@ -131,7 +113,7 @@ struct mu_sql_dispatch
};
/* Public interfaces */
-int mu_sql_interface_index (char *name);
+int mu_sql_interface_index (char const *name);
int mu_sql_connection_init (mu_sql_connection_t *conn, int interface,
char *server, int port, char *login,
diff --git a/include/mailutils/tls.h b/include/mailutils/tls.h
index db6e420ad..16b1ecb12 100644
--- a/include/mailutils/tls.h
+++ b/include/mailutils/tls.h
@@ -42,8 +42,6 @@ struct mu_tls_module_config
char *priorities;
};
-extern int mu_tls_module_init (enum mu_gocs_op, void *);
-
extern int mu_tls_server_stream_create (mu_stream_t *stream,
mu_stream_t strin, mu_stream_t strout,
int flags);
diff --git a/include/mailutils/types.hin b/include/mailutils/types.hin
index 770b989ce..1057239d6 100644
--- a/include/mailutils/types.hin
+++ b/include/mailutils/types.hin
@@ -151,12 +151,6 @@ struct mu_locus
unsigned mu_col;
};
-enum mu_gocs_op
- {
- mu_gocs_op_set,
- mu_gocs_op_flush
- };
-
#ifdef __cplusplus
}
#endif

Return to:

Send suggestions and report system problems to the System administrator.