aboutsummaryrefslogtreecommitdiff
path: root/manage.h
diff options
context:
space:
mode:
authorjames <james@e7ae566f-a301-0410-adde-c780ea21d3b5>2006-11-13 09:31:40 +0000
committerjames <james@e7ae566f-a301-0410-adde-c780ea21d3b5>2006-11-13 09:31:40 +0000
commit2c21891ec156adc304f4012343d75808a1036d0f (patch)
treebae7dffb6eefb75ee653848bc1926b188eaf917b /manage.h
parentBacked out AUTO_USERID feature introduced in r1436. (diff)
downloadopenvpn-2c21891ec156adc304f4012343d75808a1036d0f.tar.xz
Attempt at rational signal handling when in the
management hold state. During management hold, ignore SIGUSR1/SIGHUP signals thrown with the "signal" command. Also, "signal" command will now apply remapping as specified with the --remap-usr1 option. When a signal entered using the "signal" command from a management hold is ignored, output: >HOLD:Waiting for hold release git-svn-id: http://svn.openvpn.net/projects/openvpn/branches/BETA21/openvpn@1458 e7ae566f-a301-0410-adde-c780ea21d3b5
Diffstat (limited to 'manage.h')
-rw-r--r--manage.h9
1 files changed, 8 insertions, 1 deletions
diff --git a/manage.h b/manage.h
index c7cce07..445f710 100644
--- a/manage.h
+++ b/manage.h
@@ -207,6 +207,12 @@ struct man_settings {
bool hold;
bool connect_as_client;
char *write_peer_info_file;
+
+/* flags for handling the management interface "signal" command */
+# define MANSIG_IGNORE_USR1_HUP (1<<0)
+# define MANSIG_MAP_USR1_TO_HUP (1<<1)
+# define MANSIG_MAP_USR1_TO_TERM (1<<2)
+ unsigned int mansig;
};
/* up_query modes */
@@ -276,7 +282,8 @@ bool management_open (struct management *man,
const int state_buffer_size,
const bool hold,
const bool connect_as_client,
- const char *write_peer_info_file);
+ const char *write_peer_info_file,
+ const int remap_sigusr1);
void management_close (struct management *man);