Unverified Commit 460d233e by Christian Brauner Committed by Stéphane Graber

confile: add clearer for lxc.stopsignal

parent 7f358ad8
......@@ -201,6 +201,7 @@ static int clr_config_rebootsignal(const char *, struct lxc_conf *);
static int set_config_stopsignal(const char *, const char *, struct lxc_conf *);
static int get_config_stopsignal(const char *, char *, int, struct lxc_conf *);
static int clr_config_stopsignal(const char *, struct lxc_conf *);
static int set_config_start(const char *, const char *, struct lxc_conf *);
static int get_config_start(const char *, char *, int, struct lxc_conf *);
......@@ -284,7 +285,7 @@ static struct lxc_config_t config[] = {
{ "lxc.autodev", set_config_autodev, get_config_autodev, clr_config_autodev, },
{ "lxc.haltsignal", set_config_haltsignal, get_config_haltsignal, clr_config_haltsignal, },
{ "lxc.rebootsignal", set_config_rebootsignal, get_config_rebootsignal, clr_config_rebootsignal, },
{ "lxc.stopsignal", set_config_stopsignal, get_config_stopsignal, NULL },
{ "lxc.stopsignal", set_config_stopsignal, get_config_stopsignal, clr_config_stopsignal, },
{ "lxc.start.auto", set_config_start, get_config_start, NULL },
{ "lxc.start.delay", set_config_start, get_config_start, NULL },
{ "lxc.start.order", set_config_start, get_config_start, NULL },
......@@ -2564,9 +2565,6 @@ int lxc_clear_config_item(struct lxc_conf *c, const char *key)
} else if (strncmp(key, "lxc.environment", 15) == 0) {
ret = lxc_clear_environment(c);
} else if (strcmp(key, "lxc.stopsignal") == 0) {
c->stopsignal = 0;
} else if (strcmp(key, "lxc.init_cmd") == 0) {
free(c->init_cmd);
c->init_cmd = NULL;
......@@ -3857,3 +3855,9 @@ static inline int clr_config_rebootsignal(const char *key, struct lxc_conf *c)
c->rebootsignal = 0;
return 0;
}
static inline int clr_config_stopsignal(const char *key, struct lxc_conf *c)
{
c->stopsignal = 0;
return 0;
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment