aboutsummaryrefslogtreecommitdiffstats
path: root/src/n3.c
diff options
context:
space:
mode:
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 6813bccc..79a48a93 100644
--- a/src/n3.c
+++ b/src/n3.c
@@ -369,7 +369,7 @@ resolve_IRIREF(SerdReader* const reader,
temp->length = serd_write_uri(uri, write_to_stack, &ctx);
if (!ctx.status) {
// Replace the destination with the new expanded node
- memmove(dest, temp, serd_node_total_size(temp));
+ memmove(dest, temp, sizeof(SerdNode) + serd_node_pad_length(temp->length));
serd_stack_pop_to(&reader->stack, string_start_offset + dest->length);
}
@@ -438,7 +438,8 @@ read_PrefixedName(SerdReader* const reader,
}
// Replace the destination with the new expanded node
- const size_t total_size = serd_node_total_size(temp);
+ const size_t total_size =
+ sizeof(SerdNode) + serd_node_pad_length(temp->length);
memmove(dest, temp, total_size);