[PATCH] Fix type for write(2) return variable.

From: Quentin Rameau <quinq_AT_fifth.space>
Date: Fri, 24 Jul 2015 11:40:46 +0200

The allocated lengh of s fits into an integer so we can safely use
ssize_t here.
---
 st.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/st.c b/st.c
index b604f0e..f53378c 100644
--- a/st.c
+++ b/st.c
_AT_@ -560,7 +560,8 @@ static int frclen = 0;
 ssize_t
 xwrite(int fd, const char *s, size_t len)
 {
-	size_t aux = len, r;
+	size_t aux = len;
+	ssize_t r;
 
 	while (len > 0) {
 		r = write(fd, s, len);
-- 
2.4.6
--wVvLJV8Os4vjfz3/--
Received on Mon Sep 17 2001 - 00:00:00 CEST

This archive was generated by hypermail 2.3.0 : Fri Jul 24 2015 - 12:00:13 CEST