Mesa (staging/20.0): util/os_socket: Include unistd.h to fix build error
GitLab Mirror
gitlab-mirror at kemper.freedesktop.org
Mon Feb 3 17:01:08 UTC 2020
Module: Mesa
Branch: staging/20.0
Commit: b5a345595a1be0d7fab2f03c768c84968cd40ab3
URL: http://cgit.freedesktop.org/mesa/mesa/commit/?id=b5a345595a1be0d7fab2f03c768c84968cd40ab3
Author: Bernd Kuhls <bernd.kuhls at t-online.de>
Date: Fri Jan 31 18:48:06 2020 +0100
util/os_socket: Include unistd.h to fix build error
Fixes
In file included from ../src/util/os_socket.c:8:
../src/util/os_socket.h:26:1: error: unknown type name ‘ssize_t’; did you mean ‘size_t’?
ssize_t os_socket_recv(int socket, void *buffer, size_t length, int flags);
seen with gcc version 8.3.0 (Buildroot 2019.11) and uClibc 1.0.32.
Reviewed-by: Eric Engestrom <eric at engestrom.ch>
Fixes: ef5266ebd50e7fa65c56 ("util/os_socket: Add socket related functions.")
Tested-by: Marge Bot <https://gitlab.freedesktop.org/mesa/mesa/merge_requests/3659>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/merge_requests/3659>
(cherry picked from commit e62c3cf350a8b169e6401d5f1e1f17388cdc4b77)
---
.pick_status.json | 2 +-
src/util/os_socket.h | 1 +
2 files changed, 2 insertions(+), 1 deletion(-)
diff --git a/.pick_status.json b/.pick_status.json
index 0c81b8b1756..51c9153b370 100644
--- a/.pick_status.json
+++ b/.pick_status.json
@@ -58,7 +58,7 @@
"description": "util/os_socket: Include unistd.h to fix build error",
"nominated": true,
"nomination_type": 1,
- "resolution": 0,
+ "resolution": 1,
"master_sha": null,
"because_sha": "ef5266ebd50e7fa65c56bdb623e12ca8c233b470"
},
diff --git a/src/util/os_socket.h b/src/util/os_socket.h
index 0d6f8749176..db0dc905a2b 100644
--- a/src/util/os_socket.h
+++ b/src/util/os_socket.h
@@ -10,6 +10,7 @@
#include <stdio.h>
#include <stdbool.h>
+#include <unistd.h>
#ifdef _MSC_VER
#include <BaseTsd.h>
typedef SSIZE_T ssize_t;
More information about the mesa-commit
mailing list