From e1791bb11ae85366dfb4d0173a8d7b5751a7a407 Mon Sep 17 00:00:00 2001 From: james Date: Tue, 4 Oct 2005 11:51:44 +0000 Subject: Added support for openvpn_plugin_select_initialization_point_v1 2.1_beta1 git-svn-id: http://svn.openvpn.net/projects/openvpn/branches/BETA21/openvpn@591 e7ae566f-a301-0410-adde-c780ea21d3b5 --- plugin/auth-pam/.svnignore | 1 + plugin/auth-pam/auth-pam.c | 8 +++++++- 2 files changed, 8 insertions(+), 1 deletion(-) create mode 100644 plugin/auth-pam/.svnignore (limited to 'plugin/auth-pam') diff --git a/plugin/auth-pam/.svnignore b/plugin/auth-pam/.svnignore new file mode 100644 index 0000000..140f8cf --- /dev/null +++ b/plugin/auth-pam/.svnignore @@ -0,0 +1 @@ +*.so diff --git a/plugin/auth-pam/auth-pam.c b/plugin/auth-pam/auth-pam.c index 5047b34..a2b2934 100644 --- a/plugin/auth-pam/auth-pam.c +++ b/plugin/auth-pam/auth-pam.c @@ -48,7 +48,7 @@ #include "openvpn-plugin.h" -#define DEBUG(verb) ((verb) >= 7) +#define DEBUG(verb) ((verb) >= 4) /* Command codes for foreground -> background communication */ #define COMMAND_VERIFY 0 @@ -206,6 +206,8 @@ send_string (int fd, const char *string) return -1; } +#ifdef DO_DAEMONIZE + /* * Daemonize if "daemon" env var is true. * Preserve stderr across daemonization if @@ -233,6 +235,8 @@ daemonize (const char *envp[]) } } +#endif + /* * Close most of parent's fds. * Keep stdin/stdout/stderr, plus one @@ -405,8 +409,10 @@ openvpn_plugin_open_v1 (unsigned int *type_mask, const char *argv[], const char /* Ignore most signals (the parent will receive them) */ set_signals (); +#ifdef DO_DAEMONIZE /* Daemonize if --daemon option is set. */ daemonize (envp); +#endif /* execute the event loop */ pam_server (fd[1], argv[1], context->verb, &name_value_list); -- cgit