Mesa (master): util/os_file: fix error being sign-cast back and forth

GitLab Mirror gitlab-mirror at kemper.freedesktop.org
Sun Jun 9 13:22:50 UTC 2019


Module: Mesa
Branch: master
Commit: fd5c18de883cbf56fe925fc3f3ff3031ed535377
URL:    http://cgit.freedesktop.org/mesa/mesa/commit/?id=fd5c18de883cbf56fe925fc3f3ff3031ed535377

Author: Eric Engestrom <eric.engestrom at intel.com>
Date:   Thu May 16 13:08:53 2019 +0100

util/os_file: fix error being sign-cast back and forth

Signed-off-by: Eric Engestrom <eric.engestrom at intel.com>
Reviewed-by: Eric Anholt <eric at anholt.net>

---

 src/util/os_file.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/util/os_file.c b/src/util/os_file.c
index 400a2a12c4d..6e78a231d67 100644
--- a/src/util/os_file.c
+++ b/src/util/os_file.c
@@ -37,7 +37,7 @@ readN(int fd, char *buf, size_t len)
       total += ret;
    } while (total != len);
 
-   return total ? total : err;
+   return total ? (ssize_t)total : err;
 }
 
 char *




More information about the mesa-commit mailing list