summaryrefslogtreecommitdiff
path: root/alpine/roleconf.c
diff options
context:
space:
mode:
Diffstat (limited to 'alpine/roleconf.c')
-rw-r--r--alpine/roleconf.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/alpine/roleconf.c b/alpine/roleconf.c
index 0ee3ec8..378baa8 100644
--- a/alpine/roleconf.c
+++ b/alpine/roleconf.c
@@ -7707,6 +7707,11 @@ role_text_tool_inick(struct pine *ps, int cmd, CONF_S **cl, unsigned int flags)
if(apval)
*apval = (role && role->nick) ? cpystr(role->nick) : NULL;
+ if (ps_global->role)
+ fs_give((void **)&ps_global->role);
+ if (role && role->nick)
+ ps_global->role = cpystr(role->nick);
+
if((*cl)->value)
fs_give((void **)&((*cl)->value));