Fix problems reported by HP aC++/C compiler.
Alex Cherepanov <[email protected]> Tue, 14 Sep 2004 23:38:40 -0400
| Newsgroups | gmane.comp.printing.ghostscript.patches |
|---|---|
| Organization | Coscript Software |
| Message-ID | <[email protected]> |
Fix the problems reported by HP aC++/C compiler but unrelated to the crash. Partial fix for 687643. [DETAILS] gs.c, int.mak - include the prototype of gs_malloc_init() ttfmain.c - fix partly initialized FixMatrix m; gdevpsd.c - allocate 4 elements for CMYK, not 3. _______________________________________________ gs-code-review mailing list [email protected] http://www.ghostscript.com/mailman/listinfo/gs-code-review
hp_wng.diff
(text/plain, 2.1 KB)
Index: gs/src/gs.c
===================================================================
RCS file: /cvs/ghostscript/gs/src/gs.c,v
retrieving revision 1.12
diff -b -u -r1.12 gs.c
--- gs/src/gs.c 4 Aug 2004 19:36:12 -0000 1.12
+++ gs/src/gs.c 15 Sep 2004 03:18:56 -0000
@@ -22,6 +22,7 @@
#include "iapi.h"
#include "iminst.h"
#include "ierrors.h"
+#include "gsmalloc.h"
/* Define an optional array of strings for testing. */
/*#define RUN_STRINGS */
Index: gs/src/int.mak
===================================================================
RCS file: /cvs/ghostscript/gs/src/int.mak,v
retrieving revision 1.129
diff -b -u -r1.129 int.mak
--- gs/src/int.mak 3 Sep 2004 20:23:10 -0000 1.129
+++ gs/src/int.mak 15 Sep 2004 03:18:56 -0000
@@ -1938,7 +1938,7 @@
# ============================= Main program ============================== #
$(PSOBJ)gs.$(OBJ) : $(PSSRC)gs.c $(GH)\
- $(ierrors_h) $(iapi_h) $(imain_h) $(imainarg_h) $(iminst_h)
+ $(ierrors_h) $(iapi_h) $(imain_h) $(imainarg_h) $(iminst_h) $(gsmalloc_h)
$(PSCC) $(PSO_)gs.$(OBJ) $(C_) $(PSSRC)gs.c
$(PSOBJ)iapi.$(OBJ) : $(PSSRC)iapi.c $(AK)\
Index: gs/src/ttfmain.c
===================================================================
RCS file: /cvs/ghostscript/gs/src/ttfmain.c,v
retrieving revision 1.27
diff -b -u -r1.27 ttfmain.c
--- gs/src/ttfmain.c 19 Mar 2004 10:08:10 -0000 1.27
+++ gs/src/ttfmain.c 15 Sep 2004 03:18:56 -0000
@@ -588,7 +588,7 @@
arg2 = ttfReader__Byte(r);
}
}
- m.b = m.c = 0;
+ m.b = m.c = m.tx = m.ty = 0;
if (flags & WE_HAVE_A_SCALE)
m.a = m.d = (Fixed)ttfReader__Short(r) << 2;
else if (flags & WE_HAVE_AN_X_AND_Y_SCALE) {
Index: gs/src/gdevpsd.c
===================================================================
RCS file: /cvs/ghostscript/gs/src/gdevpsd.c,v
retrieving revision 1.16
diff -b -u -r1.16 gdevpsd.c
--- gs/src/gdevpsd.c 1 Jul 2004 04:41:38 -0000 1.16
+++ gs/src/gdevpsd.c 15 Sep 2004 03:18:56 -0000
@@ -342,7 +342,7 @@
int i;
if (luo != NULL) {
- double in[3];
+ double in[4];
double tmp[MAX_CHAN];
int outn = xdev->lu_cmyk_outn;