aboutsummaryrefslogtreecommitdiffstats
path: root/src/n3.c
diff options
context:
space:
mode:
authorDavid Robillard <d@drobilla.net>2021-07-24 21:08:10 -0400
committerDavid Robillard <d@drobilla.net>2023-12-02 18:49:07 -0500
commit6f87e81df367d93f327cebbc6e848ffd09742761 (patch)
treea7343cb271a1caeebae31a73f50bcdecb2854414 /src/n3.c
parent2d43bf2b5c301ca1e4766b5048650ca1e29e38c0 (diff)
downloadserd-6f87e81df367d93f327cebbc6e848ffd09742761.tar.gz
serd-6f87e81df367d93f327cebbc6e848ffd09742761.tar.bz2
serd-6f87e81df367d93f327cebbc6e848ffd09742761.zip
Be precise about the meaning of node "length" and "size"
Diffstat (limited to 'src/n3.c')
-rw-r--r--src/n3.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/n3.c b/src/n3.c
index e7af476e..dab83b12 100644
--- a/src/n3.c
+++ b/src/n3.c
@@ -1331,7 +1331,8 @@ read_collection(SerdReader* const reader,
/* The order of node allocation here is necessarily not in stack order,
so we create two nodes and recycle them throughout. */
SerdNode* n1 =
- push_node_padded(reader, genid_size(reader), SERD_BLANK, "", 0);
+ push_node_padded(reader, genid_length(reader), SERD_BLANK, "", 0);
+
SerdNode* node = n1;
SerdNode* rest = 0;
@@ -1355,7 +1356,7 @@ read_collection(SerdReader* const reader,
rest = blank_id(reader); // First pass, push
assert(rest); // Can't overflow since read_object() popped
} else {
- set_blank_id(reader, rest, genid_size(reader));
+ set_blank_id(reader, rest, genid_length(reader) + 1);
}
}