xserver: Branch 'master'

Adam Jackson ajax at kemper.freedesktop.org
Wed Mar 1 20:14:54 UTC 2017


 configure.ac |    1 +
 os/auth.c    |    2 +-
 2 files changed, 2 insertions(+), 1 deletion(-)

New commits:
commit 386fbbe410a1168b724136e54cf3bd37fb64ad4e
Author: Matthieu Herrb <matthieu at herrb.eu>
Date:   Wed Mar 1 20:28:34 2017 +0100

    Brown bag commit to fix 957e8d (arc4random_buf() support)
    
    - typo in #ifdef check
    - also need to add AC_CHECK_FUNCS([arc4random_buf])
    
    Reported-by Eric Engestrom. Thanks
    
    Reviewed-by: Adam Jackson <ajax at redhat.com>
    Signed-off-by: Matthieu Herrb <matthieu at herrb.eu>

diff --git a/configure.ac b/configure.ac
index 6a7c4cc..a613087 100644
--- a/configure.ac
+++ b/configure.ac
@@ -226,6 +226,7 @@ AC_REPLACE_FUNCS([reallocarray strcasecmp strcasestr strlcat strlcpy strndup\
 AM_CONDITIONAL(POLL, [test "x$ac_cv_func_poll" = "xyes"])
 
 AC_CHECK_LIB([bsd], [arc4random_buf])
+AC_CHECK_FUNCS([arc4random_buf])
 
 AC_CHECK_DECLS([program_invocation_short_name], [], [], [[#include <errno.h>]])
 
diff --git a/os/auth.c b/os/auth.c
index 41b625d..c7b333c 100644
--- a/os/auth.c
+++ b/os/auth.c
@@ -305,7 +305,7 @@ GenerateAuthorization(unsigned name_length,
 void
 GenerateRandomData(int len, char *buf)
 {
-#ifdef HAVE_ARC4RANDOMBUF
+#ifdef HAVE_ARC4RANDOM_BUF
     arc4random_buf(buf, len);
 #else
     int fd;


More information about the xorg-commit mailing list