blob: db207e0e353c107377f58233ef49df1cf9accaf3 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
|
--- a/subprojects/libglnx/glnx-macros.h
+++ b/subprojects/libglnx/glnx-macros.h
@@ -28,6 +28,16 @@
G_BEGIN_DECLS
+/* taken from glibc unistd.h and fixes musl */
+#ifndef TEMP_FAILURE_RETRY
+#define TEMP_FAILURE_RETRY(expression) \
+ (__extension__ \
+ ({ long int __result; \
+ do __result = (long int) (expression); \
+ while (__result == -1L && errno == EINTR); \
+ __result; }))
+#endif
+
/* All of these are for C only. */
#ifndef __GI_SCANNER__
|