summaryrefslogtreecommitdiffstats
path: root/package/libpam-tacplus/0001-Fix-getrandom-call-in-magic.c.patch
blob: bde717f3f08409ea705ad71d03159c40a4f9bb4b (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
From 5b49ec03b165b8d7c69e196bf1c2780274fbe1ee Mon Sep 17 00:00:00 2001
From: Fabrice Fontaine <fontaine.fabrice@gmail.com>
Date: Sun, 20 May 2018 15:47:33 +0200
Subject: [PATCH] Fix getrandom call in magic.c

_GNU_SOURCE must be defined before any includes to be able to use
getrandom

Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>

[Upstream status: https://github.com/jeroennijhof/pam_tacplus/pull/118]
---
 libtac/lib/magic.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/libtac/lib/magic.c b/libtac/lib/magic.c
index 97aa035..a9cbe86 100644
--- a/libtac/lib/magic.c
+++ b/libtac/lib/magic.c
@@ -18,6 +18,7 @@
  * See `CHANGES' file for revision history.
  */
 
+#define _GNU_SOURCE
 #include <stdio.h>
 #include <stdlib.h>
 #include <sys/types.h>
-- 
2.14.1

OpenPOWER on IntegriCloud