Patrick Williams | b48b7b4 | 2016-08-17 15:04:38 -0500 | [diff] [blame^] | 1 | From 621d946e56efac2c779b83b1a5c6b645169c4ebd Mon Sep 17 00:00:00 2001 |
| 2 | From: "Brian A. Lloyd" <brian.lloyd@familyhonor.net> |
| 3 | Date: Wed, 1 Oct 2014 12:35:18 +0300 |
| 4 | Subject: [PATCH] Add config.h include to src/lx_memory.c |
| 5 | |
| 6 | The src/lx_memory.c file uses the xf86.h header file. This file must have |
| 7 | HAVE_STRNDUP defined before calling it when the building platform has a strndup |
| 8 | function. When using config.h, this file doesn't have that define and so fails |
| 9 | to compile. |
| 10 | |
| 11 | The attached patch adds the conditional config.h to this file so it may compile |
| 12 | on the affected platforms. |
| 13 | |
| 14 | The patch is trivial and may be included and used under whatever licensing |
| 15 | desired. |
| 16 | |
| 17 | Closes: Free Desktop Bug #84541 |
| 18 | |
| 19 | Signed-off-by: Brian A. Lloyd <brian.lloyd@familyhonor.net> |
| 20 | Upstream-Status: Backport |
| 21 | --- |
| 22 | src/lx_memory.c | 3 +++ |
| 23 | 1 file changed, 3 insertions(+) |
| 24 | |
| 25 | diff --git a/src/lx_memory.c b/src/lx_memory.c |
| 26 | index f26d280..992446f 100644 |
| 27 | --- a/src/lx_memory.c |
| 28 | +++ b/src/lx_memory.c |
| 29 | @@ -22,6 +22,9 @@ |
| 30 | * contributors may be used to endorse or promote products derived from this |
| 31 | * software without specific prior written permission. |
| 32 | */ |
| 33 | +#if HAVE_CONFIG_H |
| 34 | +#include "config.h" |
| 35 | +#endif |
| 36 | |
| 37 | #include "xf86.h" |
| 38 | #include "geode.h" |
| 39 | -- |
| 40 | 2.1.1 |
| 41 | |