Commit 5276aee2 authored by Emmanuele Bassi's avatar Emmanuele Bassi

Fix the getrandom() patch for Mutter

parent 48c92d47
Pipeline #90623 passed with stage
in 23 seconds
From 72231d65c1a7552e1e9b8529fa956dc6282eb9d6 Mon Sep 17 00:00:00 2001
From 73f75d6500ca8953c3f154af741bc4d9699c35c3 Mon Sep 17 00:00:00 2001
From: Emmanuele Bassi <ebassi@gnome.org>
Date: Tue, 25 Jun 2019 00:29:51 +0100
Subject: [PATCH] Add syscall fallback for getrandom()
When using linux/random.h, we need to use the syscall() interface.
---
config.h.meson | 4 ++--
meson.build | 4 ++--
src/wayland/meta-xwayland.c | 12 +++++++++++-
2 files changed, 13 insertions(+), 3 deletions(-)
3 files changed, 15 insertions(+), 5 deletions(-)
diff --git a/config.h.meson b/config.h.meson
index 77045319c..7cb66ef07 100644
--- a/config.h.meson
+++ b/config.h.meson
@@ -61,6 +61,6 @@
/* XKB base prefix */
#mesondefine XKB_BASE
-/* Either <sys/random.h> or <linux/random.h> */
+/* We either have getrandom() in sys/random.h, or we have to use syscall() */
#mesondefine HAVE_SYS_RANDOM
-#mesondefine HAVE_LINUX_RANDOM
+#mesondefine HAVE_GETRANDOM_SYSCALL
diff --git a/meson.build b/meson.build
index d01b42c19..46231f03d 100644
--- a/meson.build
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment