perf tools: Use correct return type for readn function
[deliverable/linux.git] / tools / perf / util / util.c
index 28a0a89c1f739749a59c8b80aa3d3b37d8f4000f..9440481e9092a104e068788b7c6ef66584fc8af6 100644 (file)
@@ -151,12 +151,12 @@ unsigned long convert_unit(unsigned long value, char *unit)
        return value;
 }
 
-int readn(int fd, void *buf, size_t n)
+ssize_t readn(int fd, void *buf, size_t n)
 {
        void *buf_start = buf;
 
        while (n) {
-               int ret = read(fd, buf, n);
+               ssize_t ret = read(fd, buf, n);
 
                if (ret <= 0)
                        return ret;
This page took 0.024961 seconds and 5 git commands to generate.