Xinqi Bao's Git

Refactor keymap.c
[slstatus.git] / slstatus.c
index 3222b02..4f7a2fc 100644 (file)
@@ -99,7 +99,9 @@ main(int argc, char *argv[])
                }
 
                if (sflag) {
-                       printf("%s\n", status);
+                       if (printf("%s\n", status) < 0) {
+                               die("printf:");
+                       }
                } else {
                        if (XStoreName(dpy, DefaultRootWindow(dpy), status) < 0) {
                                die("XStoreName: Allocation failed");