aboutsummaryrefslogtreecommitdiff
path: root/src/sc_parse.c
diff options
context:
space:
mode:
authorThomas White <taw@physics.org>2018-01-04 22:35:55 +0100
committerThomas White <taw@physics.org>2018-01-04 22:35:55 +0100
commit02828602d6f2f1ec2a7e718dea8d4bedc9dc300d (patch)
tree983ba5c7cdeaef546f28cec786ee3ac5e5848491 /src/sc_parse.c
parent785c8853383711e6e0bcbdbbcc806907cab391dc (diff)
Copy and paste entire frames
Diffstat (limited to 'src/sc_parse.c')
-rw-r--r--src/sc_parse.c12
1 files changed, 12 insertions, 0 deletions
diff --git a/src/sc_parse.c b/src/sc_parse.c
index 3853800..a8b2c09 100644
--- a/src/sc_parse.c
+++ b/src/sc_parse.c
@@ -140,6 +140,18 @@ SCBlock *sc_block_append_end(SCBlock *bl, char *name, char *opt, char *contents)
}
+void sc_block_append_block(SCBlock *bl, SCBlock *bln)
+{
+
+ if ( bl == NULL ) return;
+
+ while ( bl->next != NULL ) bl = bl->next;
+
+ bl->next = bln;
+ bln->next = NULL;
+}
+
+
/* Append a new block to the chain inside "parent".
* "name", "options" and "contents" will not be copied. Returns the block just
* created, or NULL on error. */