summaryrefslogtreecommitdiff
path: root/alpine/adrbkcmd.c
diff options
context:
space:
mode:
Diffstat (limited to 'alpine/adrbkcmd.c')
-rw-r--r--alpine/adrbkcmd.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/alpine/adrbkcmd.c b/alpine/adrbkcmd.c
index 94d9077..5c8a02a 100644
--- a/alpine/adrbkcmd.c
+++ b/alpine/adrbkcmd.c
@@ -4129,6 +4129,8 @@ ab_compose_internal(BuildTo bldto, int allow_role)
* won't do anything, but will cause compose_mail to think there's
* already a role so that it won't try to confirm the default.
*/
+ if (ps_global->role)
+ fs_give((void **)&ps_global->role);
if(role)
role = copy_action(role);
else{
@@ -4136,6 +4138,7 @@ ab_compose_internal(BuildTo bldto, int allow_role)
memset((void *)role, 0, sizeof(*role));
role->nick = cpystr("Default Role");
}
+ ps_global->role = cpystr(role->nick);
}
compose_mail(addr, fcc, role, NULL, NULL);