File 0619-kerne-Fix-os_SUITE-init_per_suite.patch of Package erlang

From 305446e8e3944671545e8c39c942e46b75c5b15a Mon Sep 17 00:00:00 2001
From: Sverker Eriksson <sverker@erlang.org>
Date: Mon, 2 Jan 2023 18:50:39 +0100
Subject: [PATCH] kerne: Fix os_SUITE:init_per_suite

On Windows:
my_fds.c(11): error C2065: 'STDIN_FILENO': undeclared identifier


Test case close_stdin skipped on Windows anyway.
---
 lib/kernel/test/os_SUITE_data/my_fds.c | 5 +++++
 1 file changed, 5 insertions(+)

diff --git a/lib/kernel/test/os_SUITE_data/my_fds.c b/lib/kernel/test/os_SUITE_data/my_fds.c
index 9b51db514e..dedb113c70 100644
--- a/lib/kernel/test/os_SUITE_data/my_fds.c
+++ b/lib/kernel/test/os_SUITE_data/my_fds.c
@@ -7,7 +7,12 @@
 int
 main(int argc, char** argv)
 {
+#if defined (__WIN32__)
+    printf("Windows");
+#else
     char buff[1];
     int res = read(STDIN_FILENO, buff, 1);
     printf("%d", res);
+#endif
+    return 0;
 }
-- 
2.35.3

openSUSE Build Service is sponsored by