summary refs log tree commit diff
path: root/Src/signals.c
diff options
context:
space:
mode:
Diffstat (limited to 'Src/signals.c')
-rw-r--r--Src/signals.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/Src/signals.c b/Src/signals.c
index ad688094b..046ee6a4a 100644
--- a/Src/signals.c
+++ b/Src/signals.c
@@ -755,7 +755,10 @@ dosavetrap(int sig, int level)
 	    newshf->node.flags = shf->node.flags;
 	    newshf->funcdef = dupeprog(shf->funcdef, 0);
 	    newshf->filename = ztrdup(shf->filename);
-	    newshf->emulation = shf->emulation;
+	    if (shf->sticky) {
+		newshf->sticky = sticky_emulation_dup(shf->sticky, 0);
+	    } else
+		newshf->sticky = 0;
 	    if (shf->node.flags & PM_UNDEFINED)
 		newshf->funcdef->shf = newshf;
 	}