summary refs log tree commit diff
diff options
context:
space:
mode:
-rw-r--r--scoop.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/scoop.c b/scoop.c
index 241ef3e..006a416 100644
--- a/scoop.c
+++ b/scoop.c
@@ -123,8 +123,10 @@ static const char *ansi(const char *str) {
 			}
 		}
 	}
-
+	fprintf(out, "\33[m");
 	fclose(out);
+
+	buf[sizeof(buf) - 1] = '\0';
 	return buf;
 }