summaryrefslogtreecommitdiff
path: root/data.c
diff options
context:
space:
mode:
authordefault <nobody@localhost>2022-09-23 00:00:25 +0200
committerdefault <nobody@localhost>2022-09-23 00:00:25 +0200
commitb84267e4d3dc34c4a422f9be877246792c57ce87 (patch)
tree87a6dc6eb3862c4ae3421d3d6f0bbf7be4bbdb1f /data.c
parent51dc99a86d3b10b5bcea52346f1e912daabe3c76 (diff)
_timeline_parent() does not need to be recursive (or does it?).
Diffstat (limited to 'data.c')
-rw-r--r--data.c7
1 files changed, 2 insertions, 5 deletions
diff --git a/data.c b/data.c
index 878a2c5..d6e8662 100644
--- a/data.c
+++ b/data.c
@@ -403,8 +403,8 @@ void _timeline_parent(snac *snac, char *parent, char *child)
xs *children;
/* get the children list */
- meta = xs_dict_get(msg, "_snac");
- children = xs_dict_get(meta, "children");
+ meta = xs_dup(xs_dict_get(msg, "_snac"));
+ children = xs_dup(xs_dict_get(meta, "children"));
/* add */
children = xs_list_append(children, child);
@@ -438,9 +438,6 @@ void _timeline_parent(snac *snac, char *parent, char *child)
snac_debug(snac, 1,
xs_fmt("_timeline_parent (local) updated %s %s", parent, lfn));
}
-
- /* retry with grampa */
- _timeline_parent(snac, xs_dict_get(meta, "parent"), parent);
}
else
snac_log(snac, xs_fmt("_timeline_parent error writing %s %s", parent, nfn));