aboutsummaryrefslogtreecommitdiffstats
path: root/src/world.c
diff options
context:
space:
mode:
authorDavid Robillard <d@drobilla.net>2018-05-27 15:48:25 +0200
committerDavid Robillard <d@drobilla.net>2018-12-31 12:15:40 -0500
commit6650e22960f4dcd7d66dc560aae0347dc3272e1d (patch)
treec5942a6ae5a510c093eefe9ca3a50c889911518e /src/world.c
parent85627db501282f3cb49223b816dbc226bd99ca16 (diff)
downloadserd-6650e22960f4dcd7d66dc560aae0347dc3272e1d.tar.gz
serd-6650e22960f4dcd7d66dc560aae0347dc3272e1d.tar.bz2
serd-6650e22960f4dcd7d66dc560aae0347dc3272e1d.zip
WIP: Add validation
Diffstat (limited to 'src/world.c')
-rw-r--r--src/world.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/world.c b/src/world.c
index 483c46a6..f038f031 100644
--- a/src/world.c
+++ b/src/world.c
@@ -53,10 +53,12 @@ serd_world_fopen(SerdWorld* world, const char* path, const char* mode)
SerdStatus
serd_world_log(const SerdWorld* world, const SerdMessage* msg)
{
+ static const char* level_strings[] = { "note", "warning", "error" };
+
if (world->msg_sink) {
world->msg_sink(world->msg_handle, msg);
} else {
- fprintf(stderr, "error: ");
+ fprintf(stderr, "%s: ", level_strings[msg->level]);
if (msg->cursor) {
fprintf(stderr,
"%s:%u:%u: ",