4178
|
1 diff -ur fig2dev-3.2.6-rc.orig/fig2dev/dev/genbitmaps.c fig2dev-3.2.6-rc/fig2dev/dev/genbitmaps.c |
|
2 --- fig2dev-3.2.6-rc.orig/fig2dev/dev/genbitmaps.c 2016-07-21 12:56:13.331222524 -0400 |
|
3 +++ fig2dev-3.2.6-rc/fig2dev/dev/genbitmaps.c 2016-07-21 13:01:11.202891975 -0400 |
|
4 @@ -160,7 +160,9 @@ |
|
5 if (tfp != stdout) |
|
6 fclose(tfp); |
|
7 |
|
8 +#if ! defined (__WIN32__) || defined (__CYGWIN__) |
|
9 (void) signal(SIGPIPE, gs_broken_pipe); |
|
10 +#endif |
|
11 if ((tfp = popen(gscom,"w" )) == 0) { |
|
12 fprintf(stderr,"fig2dev: Can't open pipe to ghostscript\n"); |
|
13 fprintf(stderr,"command was: %s\n", gscom); |
|
14 @@ -191,7 +193,9 @@ |
|
15 fprintf(stderr,"command was: %s\n", gscom); |
|
16 return -1; |
|
17 } |
|
18 +#if ! defined (__WIN32__) || defined (__CYGWIN__) |
|
19 (void) signal(SIGPIPE, SIG_DFL); |
|
20 +#endif |
|
21 |
|
22 /* all ok so far */ |
|
23 status = 0; |
|
24 diff -ur fig2dev-3.2.6-rc.orig/fig2dev/dev/genpdf.c fig2dev-3.2.6-rc/fig2dev/dev/genpdf.c |
|
25 --- fig2dev-3.2.6-rc.orig/fig2dev/dev/genpdf.c 2016-07-21 13:04:33.941910210 -0400 |
|
26 +++ fig2dev-3.2.6-rc/fig2dev/dev/genpdf.c 2016-07-21 13:05:54.091731415 -0400 |
|
27 @@ -56,7 +56,9 @@ |
|
28 sprintf(gscom, |
|
29 "gs -q -dNOPAUSE -sAutoRotatePages=None -dAutoFilterColorImages=false -dColorImageFilter=/DCTEncode -sDEVICE=pdfwrite -dPDFSETTINGS=/prepress -sOutputFile=\'%s\' - -c quit", |
|
30 ofile); |
|
31 +#if !defined (__WIN32__) || defined (__CYGWIN__) |
|
32 (void) signal(SIGPIPE, gs_broken_pipe); |
|
33 +#endif |
|
34 if ((tfp = popen(gscom,"w" )) == 0) { |
|
35 fprintf(stderr,"fig2dev: Can't open pipe to ghostscript\n"); |
|
36 fprintf(stderr,"command was: %s\n", gscom); |
|
37 @@ -82,7 +84,9 @@ |
|
38 fprintf(stderr,"command was: %s\n", gscom); |
|
39 return -1; |
|
40 } |
|
41 +#if !defined (__WIN32__) || defined (__CYGWIN__) |
|
42 (void) signal(SIGPIPE, SIG_DFL); |
|
43 +#endif |
|
44 |
|
45 /* all ok so far */ |
|
46 |
|
47 diff -ur fig2dev-3.2.6-rc.orig/fig2dev/dev/genps.c fig2dev-3.2.6-rc/fig2dev/dev/genps.c |
|
48 --- fig2dev-3.2.6-rc.orig/fig2dev/dev/genps.c 2016-07-21 13:13:08.193346910 -0400 |
|
49 +++ fig2dev-3.2.6-rc/fig2dev/dev/genps.c 2016-07-21 13:14:08.520459655 -0400 |
|
50 @@ -120,8 +120,10 @@ |
|
51 static bool ellipse_exist(F_compound *ob); |
|
52 static bool approx_spline_exist(F_compound *ob); |
|
53 static void draw_gridline(float x1, float y1, float x2, float y2); |
|
54 +#ifdef HAVE_X11_XPM_H |
|
55 static void convert_xpm_colors(unsigned char cmap[3][MAXCOLORMAPSIZE], |
|
56 XpmColor *coltabl, int ncols); |
|
57 +#endif |
|
58 static void genps_itp_spline(F_spline *s); |
|
59 static void genps_ctl_spline(F_spline *s); |
|
60 |
|
61 diff -ur fig2dev-3.2.6-rc.orig/fig2dev/lib/realloc.c fig2dev-3.2.6-rc/fig2dev/lib/realloc.c |
|
62 --- fig2dev-3.2.6-rc.orig/fig2dev/lib/realloc.c 2016-07-21 13:17:46.898252242 -0400 |
|
63 +++ fig2dev-3.2.6-rc/fig2dev/lib/realloc.c 2016-07-21 13:23:33.706176197 -0400 |
|
64 @@ -37,6 +37,8 @@ |
|
65 void * |
|
66 rpl_realloc(void *p, size_t n) |
|
67 { |
|
68 + void * result; |
|
69 + |
|
70 if (n == 0) { |
|
71 n = 1; |
|
72 free(p); |
|
73 @@ -49,6 +51,7 @@ |
|
74 result = malloc(n); |
|
75 } else { |
|
76 result = realloc(p, n); |
|
77 + } |
|
78 |
|
79 return result; |
|
80 } |
|
81 Only in fig2dev-3.2.6-rc/fig2dev/dev: .genemf.c.swp |
|
82 diff -ur fig2dev-3.2.6-rc.orig/fig2dev/dev/readpng.c fig2dev-3.2.6-rc/fig2dev/dev/readpng.c |
|
83 --- fig2dev-3.2.6-rc.orig/fig2dev/dev/readpng.c 2016-07-21 13:26:42.408414261 -0400 |
|
84 +++ fig2dev-3.2.6-rc/fig2dev/dev/readpng.c 2016-07-21 13:34:28.790596818 -0400 |
|
85 @@ -18,6 +18,11 @@ |
|
86 #include "colors.h" /* rgb2luminance() */ |
|
87 #include <png.h> |
|
88 |
|
89 +#if defined(__WIN32__) && !defined(__CYGWIN__) |
|
90 + #include <string.h> |
|
91 + #define bcopy(a,b,c) memcpy(a,b,c) |
|
92 +#endif |
|
93 + |
|
94 /* return codes: 1 : success |
|
95 0 : invalid file |
|
96 */ |