aboutsummaryrefslogtreecommitdiffstats
path: root/meta/recipes-extended/ghostscript/ghostscript/base-genht.c-add-a-preprocessor-define-to-allow-fope.patch
blob: d97d4ecd7db851e50a6895b2906e19db586724e1 (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
31
32
33
34
35
36
base/genht.c: add a preprocessor define to allow fopen calling

The commit in upstream:
http://git.ghostscript.com/?p=ghostpdl.git;a=commitdiff;h=773c69e46e70bdd5482676437dafd2ca83397643

Replace all fopen calls with gp_fopen and add a preprocessor define so
that any unintential calls directly to fopen will cause an error.

Only exceptions are those in the platform specific code, and mkromfs.c.
This patch add a preprocessor define to allow fopen calling in base/genht.c.

Upstream-Status: Pending

Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
---
 base/genht.c | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/base/genht.c b/base/genht.c
index 4b04085..cc82fff 100644
--- a/base/genht.c
+++ b/base/genht.c
@@ -16,6 +16,10 @@
 
 /* Generate C code for compiling halftones into ROM. */
 #include "malloc_.h"
+
+/* prevent gp.h from defining fopen */
+#define fopen fopen
+
 #include "stdio_.h"
 #include "string_.h"
 #include "gscdefs.h"
-- 
1.8.1.2