improve error messages

Log an error when we send an error to the client so that we don't need
to log and error anymore.
Improve the error messages when we can
Move some warnings and errors to debug
This commit is contained in:
Wim Taymans 2020-02-21 15:02:55 +01:00
parent ee617682c3
commit b33bd68bac
12 changed files with 56 additions and 62 deletions

View file

@ -215,6 +215,8 @@ pw_core_resource_errorv(struct pw_resource *resource, uint32_t id, int seq,
char buffer[1024];
vsnprintf(buffer, sizeof(buffer), message, args);
buffer[1023] = '\0';
pw_log_error("resource %p: id:%d seq:%d res:%d (%s) msg:\"%s\"",
resource, id, seq, res, spa_strerror(res), buffer);
pw_core_resource_error(resource, id, seq, res, buffer);
}