aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/reader.c2
-rw-r--r--src/serdi.c2
-rw-r--r--src/write.c3
3 files changed, 3 insertions, 4 deletions
diff --git a/src/reader.c b/src/reader.c
index 070dc7a7..f3b2d99d 100644
--- a/src/reader.c
+++ b/src/reader.c
@@ -735,7 +735,7 @@ read_language(SerdReader parser)
return 0;
}
Ref str = push_string(parser, "", 1);
- push_byte(parser, str, start);
+ push_byte(parser, str, eat_byte(parser, start));
uint8_t c;
while ((c = peek_byte(parser)) && in_range(c, 'a', 'z')) {
push_byte(parser, str, eat_byte(parser, c));
diff --git a/src/serdi.c b/src/serdi.c
index d9554679..549bf2bd 100644
--- a/src/serdi.c
+++ b/src/serdi.c
@@ -163,7 +163,7 @@ main(int argc, char** argv)
FILE* out_fd = stdout;
if (!in_fd) {
- fprintf(stderr, "failed to open file\n");
+ fprintf(stderr, "failed to open file %s\n", in_filename);
return 1;
}
diff --git a/src/write.c b/src/write.c
index 95b2c2f2..e4d524c6 100644
--- a/src/write.c
+++ b/src/write.c
@@ -165,9 +165,8 @@ serd_write_node(SerdWriter writer,
serd_write_ascii(str->buf, str->n_bytes - 1, fd, '"');
fwrite("\"", 1, 1, fd);
if (lang) {
- fwrite("@\"", 1, 2, fd);
+ fwrite("@", 1, 1, fd);
fwrite(lang->buf, 1, lang->n_bytes - 1, fd);
- fwrite("\"", 1, 1, fd);
} else if (datatype) {
fwrite("^^", 1, 2, fd);
serd_write_node(writer, URI, datatype, NULL, NULL);