spoon

set dwm status
git clone git://git.2f30.org/spoon.git
Log | Files | Refs | LICENSE

commit a1083a672848a04e871ce0e8ad96c367e55549e5
parent a0dad9bb5687f35a14c415828a24d84f1ffc1fbe
Author: sin <sin@2f30.org>
Date:   Mon Sep 26 16:51:31 +0100

Set ret to -1 on error

Diffstat:
spoon.c | 3++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/spoon.c b/spoon.c @@ -54,7 +54,7 @@ mpdread(char *buf, size_t len) if (conn == NULL) return -1; if (mpd_connection_get_error(conn) != MPD_ERROR_SUCCESS) { - warnx("cannot connect to mpd"); + ret = -1; goto out; } } @@ -90,6 +90,7 @@ mpdread(char *buf, size_t len) } return 0; out: + warnx("failed to talk to mpd"); mpd_connection_free(conn); conn = NULL; return ret;