idx int64 | func_before string | Vulnerability Classification string | vul int64 | func_after string | patch string | CWE ID string | lines_before string | lines_after string |
|---|---|---|---|---|---|---|---|---|
700 | CairoOutputDev::CairoOutputDev() {
xref = NULL;
catalog = NULL;
if (!ft_lib_initialized) {
FT_Init_FreeType(&ft_lib);
ft_lib_initialized = gTrue;
}
fontEngine = NULL;
fontEngine_owner = gFalse;
glyphs = NULL;
fill_pattern = NULL;
stroke_pattern = NULL;
stroke_opacity = 1.0;
fill_opacity ... | DoS Exec Code Overflow | 0 | CairoOutputDev::CairoOutputDev() {
xref = NULL;
catalog = NULL;
if (!ft_lib_initialized) {
FT_Init_FreeType(&ft_lib);
ft_lib_initialized = gTrue;
}
fontEngine = NULL;
fontEngine_owner = gFalse;
glyphs = NULL;
fill_pattern = NULL;
stroke_pattern = NULL;
stroke_opacity = 1.0;
fill_opacity ... | @@ -16,7 +16,7 @@
//
// Copyright (C) 2005-2008 Jeff Muizelaar <jeff@infidigm.net>
// Copyright (C) 2005, 2006 Kristian Høgsberg <krh@redhat.com>
-// Copyright (C) 2005 Albert Astals Cid <aacid@kde.org>
+// Copyright (C) 2005, 2009 Albert Astals Cid <aacid@kde.org>
// Copyright (C) 2005 Nickolay V. Shmyrev <nshmyre... | CWE-189 | null | null |
701 | void CairoOutputDev::beginMarkedContent(char *name, Dict *properties)
{
if (text)
actualText->beginMC(properties);
}
| DoS Exec Code Overflow | 0 | void CairoOutputDev::beginMarkedContent(char *name, Dict *properties)
{
if (text)
actualText->beginMC(properties);
}
| @@ -16,7 +16,7 @@
//
// Copyright (C) 2005-2008 Jeff Muizelaar <jeff@infidigm.net>
// Copyright (C) 2005, 2006 Kristian Høgsberg <krh@redhat.com>
-// Copyright (C) 2005 Albert Astals Cid <aacid@kde.org>
+// Copyright (C) 2005, 2009 Albert Astals Cid <aacid@kde.org>
// Copyright (C) 2005 Nickolay V. Shmyrev <nshmyre... | CWE-189 | null | null |
702 | void CairoOutputDev::clearSoftMask(GfxState * /*state*/) {
if (mask)
cairo_pattern_destroy(mask);
mask = NULL;
}
| DoS Exec Code Overflow | 0 | void CairoOutputDev::clearSoftMask(GfxState * /*state*/) {
if (mask)
cairo_pattern_destroy(mask);
mask = NULL;
}
| @@ -16,7 +16,7 @@
//
// Copyright (C) 2005-2008 Jeff Muizelaar <jeff@infidigm.net>
// Copyright (C) 2005, 2006 Kristian Høgsberg <krh@redhat.com>
-// Copyright (C) 2005 Albert Astals Cid <aacid@kde.org>
+// Copyright (C) 2005, 2009 Albert Astals Cid <aacid@kde.org>
// Copyright (C) 2005 Nickolay V. Shmyrev <nshmyre... | CWE-189 | null | null |
703 | void CairoOutputDev::clip(GfxState *state) {
doPath (cairo, state, state->getPath());
cairo_set_fill_rule (cairo, CAIRO_FILL_RULE_WINDING);
cairo_clip (cairo);
LOG (printf ("clip\n"));
if (cairo_shape) {
doPath (cairo_shape, state, state->getPath());
cairo_set_fill_rule (cairo_shape, CAIRO_FILL_RULE_W... | DoS Exec Code Overflow | 0 | void CairoOutputDev::clip(GfxState *state) {
doPath (cairo, state, state->getPath());
cairo_set_fill_rule (cairo, CAIRO_FILL_RULE_WINDING);
cairo_clip (cairo);
LOG (printf ("clip\n"));
if (cairo_shape) {
doPath (cairo_shape, state, state->getPath());
cairo_set_fill_rule (cairo_shape, CAIRO_FILL_RULE_W... | @@ -16,7 +16,7 @@
//
// Copyright (C) 2005-2008 Jeff Muizelaar <jeff@infidigm.net>
// Copyright (C) 2005, 2006 Kristian Høgsberg <krh@redhat.com>
-// Copyright (C) 2005 Albert Astals Cid <aacid@kde.org>
+// Copyright (C) 2005, 2009 Albert Astals Cid <aacid@kde.org>
// Copyright (C) 2005 Nickolay V. Shmyrev <nshmyre... | CWE-189 | null | null |
704 | void CairoOutputDev::drawChar(GfxState *state, double x, double y,
double dx, double dy,
double originX, double originY,
CharCode code, int nBytes, Unicode *u, int uLen)
{
if (currentFont) {
glyphs[glyphCount].index = currentFont->getGlyph (code, u, uLen);
glyphs[glyphCount].x = x -... | DoS Exec Code Overflow | 0 | void CairoOutputDev::drawChar(GfxState *state, double x, double y,
double dx, double dy,
double originX, double originY,
CharCode code, int nBytes, Unicode *u, int uLen)
{
if (currentFont) {
glyphs[glyphCount].index = currentFont->getGlyph (code, u, uLen);
glyphs[glyphCount].x = x -... | @@ -16,7 +16,7 @@
//
// Copyright (C) 2005-2008 Jeff Muizelaar <jeff@infidigm.net>
// Copyright (C) 2005, 2006 Kristian Høgsberg <krh@redhat.com>
-// Copyright (C) 2005 Albert Astals Cid <aacid@kde.org>
+// Copyright (C) 2005, 2009 Albert Astals Cid <aacid@kde.org>
// Copyright (C) 2005 Nickolay V. Shmyrev <nshmyre... | CWE-189 | null | null |
705 | void CairoImageOutputDev::drawImage(GfxState *state, Object *ref, Stream *str,
int width, int height, GfxImageColorMap *colorMap,
int *maskColors, GBool inlineImg)
{
cairo_t *cr;
cairo_surface_t *surface;
double x1, y1, x2, y2;
double *ctm;
double mat[6];
CairoImage *image;
ctm = state->g... | DoS Exec Code Overflow | 0 | void CairoImageOutputDev::drawImage(GfxState *state, Object *ref, Stream *str,
int width, int height, GfxImageColorMap *colorMap,
int *maskColors, GBool inlineImg)
{
cairo_t *cr;
cairo_surface_t *surface;
double x1, y1, x2, y2;
double *ctm;
double mat[6];
CairoImage *image;
ctm = state->g... | @@ -16,7 +16,7 @@
//
// Copyright (C) 2005-2008 Jeff Muizelaar <jeff@infidigm.net>
// Copyright (C) 2005, 2006 Kristian Høgsberg <krh@redhat.com>
-// Copyright (C) 2005 Albert Astals Cid <aacid@kde.org>
+// Copyright (C) 2005, 2009 Albert Astals Cid <aacid@kde.org>
// Copyright (C) 2005 Nickolay V. Shmyrev <nshmyre... | CWE-189 | null | null |
706 | void CairoOutputDev::drawImageMask(GfxState *state, Object *ref, Stream *str,
int width, int height, GBool invert,
GBool inlineImg) {
/* FIXME: Doesn't the image mask support any colorspace? */
cairo_set_source (cairo, fill_pattern);
/* work around a cairo bug when scaling 1x1 surfaces */
if (... | DoS Exec Code Overflow | 0 | void CairoOutputDev::drawImageMask(GfxState *state, Object *ref, Stream *str,
int width, int height, GBool invert,
GBool inlineImg) {
/* FIXME: Doesn't the image mask support any colorspace? */
cairo_set_source (cairo, fill_pattern);
/* work around a cairo bug when scaling 1x1 surfaces */
if (... | @@ -16,7 +16,7 @@
//
// Copyright (C) 2005-2008 Jeff Muizelaar <jeff@infidigm.net>
// Copyright (C) 2005, 2006 Kristian Høgsberg <krh@redhat.com>
-// Copyright (C) 2005 Albert Astals Cid <aacid@kde.org>
+// Copyright (C) 2005, 2009 Albert Astals Cid <aacid@kde.org>
// Copyright (C) 2005 Nickolay V. Shmyrev <nshmyre... | CWE-189 | null | null |
707 | void CairoOutputDev::drawImageMaskRegular(GfxState *state, Object *ref, Stream *str,
int width, int height, GBool invert,
GBool inlineImg) {
unsigned char *buffer;
unsigned char *dest;
cairo_surface_t *image;
cairo_pattern_t *pattern;
int x, y;
ImageStream *imgStr;
Guchar *pix;
cairo_mat... | DoS Exec Code Overflow | 0 | void CairoOutputDev::drawImageMaskRegular(GfxState *state, Object *ref, Stream *str,
int width, int height, GBool invert,
GBool inlineImg) {
unsigned char *buffer;
unsigned char *dest;
cairo_surface_t *image;
cairo_pattern_t *pattern;
int x, y;
ImageStream *imgStr;
Guchar *pix;
cairo_mat... | @@ -16,7 +16,7 @@
//
// Copyright (C) 2005-2008 Jeff Muizelaar <jeff@infidigm.net>
// Copyright (C) 2005, 2006 Kristian Høgsberg <krh@redhat.com>
-// Copyright (C) 2005 Albert Astals Cid <aacid@kde.org>
+// Copyright (C) 2005, 2009 Albert Astals Cid <aacid@kde.org>
// Copyright (C) 2005 Nickolay V. Shmyrev <nshmyre... | CWE-189 | null | null |
708 | void CairoOutputDev::drawLink(Link *link, Catalog *catalog) {
}
| DoS Exec Code Overflow | 0 | void CairoOutputDev::drawLink(Link *link, Catalog *catalog) {
}
| @@ -16,7 +16,7 @@
//
// Copyright (C) 2005-2008 Jeff Muizelaar <jeff@infidigm.net>
// Copyright (C) 2005, 2006 Kristian Høgsberg <krh@redhat.com>
-// Copyright (C) 2005 Albert Astals Cid <aacid@kde.org>
+// Copyright (C) 2005, 2009 Albert Astals Cid <aacid@kde.org>
// Copyright (C) 2005 Nickolay V. Shmyrev <nshmyre... | CWE-189 | null | null |
709 | void CairoImageOutputDev::drawMaskedImage(GfxState *state, Object *ref, Stream *str,
int width, int height,
GfxImageColorMap *colorMap,
Stream *maskStr,
int maskWidth, int maskHeight,
GBool maskInvert)
{
cairo_t *cr;
cairo_surface_t *surface;
double x1, y1, x2, y2;
double *ctm... | DoS Exec Code Overflow | 0 | void CairoImageOutputDev::drawMaskedImage(GfxState *state, Object *ref, Stream *str,
int width, int height,
GfxImageColorMap *colorMap,
Stream *maskStr,
int maskWidth, int maskHeight,
GBool maskInvert)
{
cairo_t *cr;
cairo_surface_t *surface;
double x1, y1, x2, y2;
double *ctm... | @@ -16,7 +16,7 @@
//
// Copyright (C) 2005-2008 Jeff Muizelaar <jeff@infidigm.net>
// Copyright (C) 2005, 2006 Kristian Høgsberg <krh@redhat.com>
-// Copyright (C) 2005 Albert Astals Cid <aacid@kde.org>
+// Copyright (C) 2005, 2009 Albert Astals Cid <aacid@kde.org>
// Copyright (C) 2005 Nickolay V. Shmyrev <nshmyre... | CWE-189 | null | null |
710 | void CairoImageOutputDev::drawSoftMaskedImage(GfxState *state, Object *ref, Stream *str,
int width, int height,
GfxImageColorMap *colorMap,
Stream *maskStr,
int maskWidth, int maskHeight,
GfxImageColorMap *maskColorMap)
{
cairo_t *cr;
cairo_surface_t *surface;
... | DoS Exec Code Overflow | 0 | void CairoImageOutputDev::drawSoftMaskedImage(GfxState *state, Object *ref, Stream *str,
int width, int height,
GfxImageColorMap *colorMap,
Stream *maskStr,
int maskWidth, int maskHeight,
GfxImageColorMap *maskColorMap)
{
cairo_t *cr;
cairo_surface_t *surface;
... | @@ -16,7 +16,7 @@
//
// Copyright (C) 2005-2008 Jeff Muizelaar <jeff@infidigm.net>
// Copyright (C) 2005, 2006 Kristian Høgsberg <krh@redhat.com>
-// Copyright (C) 2005 Albert Astals Cid <aacid@kde.org>
+// Copyright (C) 2005, 2009 Albert Astals Cid <aacid@kde.org>
// Copyright (C) 2005 Nickolay V. Shmyrev <nshmyre... | CWE-189 | null | null |
711 | void CairoOutputDev::endMarkedContent(GfxState *state)
{
if (text)
actualText->endMC(state);
}
| DoS Exec Code Overflow | 0 | void CairoOutputDev::endMarkedContent(GfxState *state)
{
if (text)
actualText->endMC(state);
}
| @@ -16,7 +16,7 @@
//
// Copyright (C) 2005-2008 Jeff Muizelaar <jeff@infidigm.net>
// Copyright (C) 2005, 2006 Kristian Høgsberg <krh@redhat.com>
-// Copyright (C) 2005 Albert Astals Cid <aacid@kde.org>
+// Copyright (C) 2005, 2009 Albert Astals Cid <aacid@kde.org>
// Copyright (C) 2005 Nickolay V. Shmyrev <nshmyre... | CWE-189 | null | null |
712 | void CairoOutputDev::endPage() {
if (text) {
text->endPage();
text->coalesce(gTrue, gFalse);
}
}
| DoS Exec Code Overflow | 0 | void CairoOutputDev::endPage() {
if (text) {
text->endPage();
text->coalesce(gTrue, gFalse);
}
}
| @@ -16,7 +16,7 @@
//
// Copyright (C) 2005-2008 Jeff Muizelaar <jeff@infidigm.net>
// Copyright (C) 2005, 2006 Kristian Høgsberg <krh@redhat.com>
-// Copyright (C) 2005 Albert Astals Cid <aacid@kde.org>
+// Copyright (C) 2005, 2009 Albert Astals Cid <aacid@kde.org>
// Copyright (C) 2005 Nickolay V. Shmyrev <nshmyre... | CWE-189 | null | null |
713 | void CairoOutputDev::endString(GfxState *state)
{
int render;
if (!currentFont)
return;
if (!glyphs)
return;
render = state->getRender();
if (render == 3 || glyphCount == 0) {
gfree(glyphs);
glyphs = NULL;
return;
}
if (!(render & 1)) {
LOG (printf ("fill string\n"));
cai... | DoS Exec Code Overflow | 0 | void CairoOutputDev::endString(GfxState *state)
{
int render;
if (!currentFont)
return;
if (!glyphs)
return;
render = state->getRender();
if (render == 3 || glyphCount == 0) {
gfree(glyphs);
glyphs = NULL;
return;
}
if (!(render & 1)) {
LOG (printf ("fill string\n"));
cai... | @@ -16,7 +16,7 @@
//
// Copyright (C) 2005-2008 Jeff Muizelaar <jeff@infidigm.net>
// Copyright (C) 2005, 2006 Kristian Høgsberg <krh@redhat.com>
-// Copyright (C) 2005 Albert Astals Cid <aacid@kde.org>
+// Copyright (C) 2005, 2009 Albert Astals Cid <aacid@kde.org>
// Copyright (C) 2005 Nickolay V. Shmyrev <nshmyre... | CWE-189 | null | null |
714 | void CairoOutputDev::endTextObject(GfxState *state) {
if (textClipPath) {
cairo_append_path (cairo, textClipPath);
cairo_clip (cairo);
if (cairo_shape) {
cairo_append_path (cairo_shape, textClipPath);
cairo_clip (cairo_shape);
}
cairo_path_destroy (textClipPath);
textClipPath = NUL... | DoS Exec Code Overflow | 0 | void CairoOutputDev::endTextObject(GfxState *state) {
if (textClipPath) {
cairo_append_path (cairo, textClipPath);
cairo_clip (cairo);
if (cairo_shape) {
cairo_append_path (cairo_shape, textClipPath);
cairo_clip (cairo_shape);
}
cairo_path_destroy (textClipPath);
textClipPath = NUL... | @@ -16,7 +16,7 @@
//
// Copyright (C) 2005-2008 Jeff Muizelaar <jeff@infidigm.net>
// Copyright (C) 2005, 2006 Kristian Høgsberg <krh@redhat.com>
-// Copyright (C) 2005 Albert Astals Cid <aacid@kde.org>
+// Copyright (C) 2005, 2009 Albert Astals Cid <aacid@kde.org>
// Copyright (C) 2005 Nickolay V. Shmyrev <nshmyre... | CWE-189 | null | null |
715 | void CairoOutputDev::endType3Char(GfxState *state) {
cairo_restore (cairo);
if (cairo_shape) {
cairo_restore (cairo_shape);
}
}
| DoS Exec Code Overflow | 0 | void CairoOutputDev::endType3Char(GfxState *state) {
cairo_restore (cairo);
if (cairo_shape) {
cairo_restore (cairo_shape);
}
}
| @@ -16,7 +16,7 @@
//
// Copyright (C) 2005-2008 Jeff Muizelaar <jeff@infidigm.net>
// Copyright (C) 2005, 2006 Kristian Høgsberg <krh@redhat.com>
-// Copyright (C) 2005 Albert Astals Cid <aacid@kde.org>
+// Copyright (C) 2005, 2009 Albert Astals Cid <aacid@kde.org>
// Copyright (C) 2005 Nickolay V. Shmyrev <nshmyre... | CWE-189 | null | null |
716 | void CairoOutputDev::eoFill(GfxState *state) {
doPath (cairo, state, state->getPath());
cairo_set_fill_rule (cairo, CAIRO_FILL_RULE_EVEN_ODD);
cairo_set_source (cairo, fill_pattern);
LOG(printf ("fill-eo\n"));
cairo_fill (cairo);
if (cairo_shape) {
cairo_set_fill_rule (cairo_shape, CAIRO_FILL_RULE_EVEN... | DoS Exec Code Overflow | 0 | void CairoOutputDev::eoFill(GfxState *state) {
doPath (cairo, state, state->getPath());
cairo_set_fill_rule (cairo, CAIRO_FILL_RULE_EVEN_ODD);
cairo_set_source (cairo, fill_pattern);
LOG(printf ("fill-eo\n"));
cairo_fill (cairo);
if (cairo_shape) {
cairo_set_fill_rule (cairo_shape, CAIRO_FILL_RULE_EVEN... | @@ -16,7 +16,7 @@
//
// Copyright (C) 2005-2008 Jeff Muizelaar <jeff@infidigm.net>
// Copyright (C) 2005, 2006 Kristian Høgsberg <krh@redhat.com>
-// Copyright (C) 2005 Albert Astals Cid <aacid@kde.org>
+// Copyright (C) 2005, 2009 Albert Astals Cid <aacid@kde.org>
// Copyright (C) 2005 Nickolay V. Shmyrev <nshmyre... | CWE-189 | null | null |
717 | void CairoOutputDev::fill(GfxState *state) {
doPath (cairo, state, state->getPath());
cairo_set_fill_rule (cairo, CAIRO_FILL_RULE_WINDING);
cairo_set_source (cairo, fill_pattern);
LOG(printf ("fill\n"));
cairo_fill (cairo);
if (cairo_shape) {
cairo_set_fill_rule (cairo_shape, CAIRO_FILL_RULE_WINDING);
... | DoS Exec Code Overflow | 0 | void CairoOutputDev::fill(GfxState *state) {
doPath (cairo, state, state->getPath());
cairo_set_fill_rule (cairo, CAIRO_FILL_RULE_WINDING);
cairo_set_source (cairo, fill_pattern);
LOG(printf ("fill\n"));
cairo_fill (cairo);
if (cairo_shape) {
cairo_set_fill_rule (cairo_shape, CAIRO_FILL_RULE_WINDING);
... | @@ -16,7 +16,7 @@
//
// Copyright (C) 2005-2008 Jeff Muizelaar <jeff@infidigm.net>
// Copyright (C) 2005, 2006 Kristian Høgsberg <krh@redhat.com>
-// Copyright (C) 2005 Albert Astals Cid <aacid@kde.org>
+// Copyright (C) 2005, 2009 Albert Astals Cid <aacid@kde.org>
// Copyright (C) 2005 Nickolay V. Shmyrev <nshmyre... | CWE-189 | null | null |
718 | static uint32_t luminocity(uint32_t x)
{
int r = (x >> 16) & 0xff;
int g = (x >> 8) & 0xff;
int b = (x >> 0) & 0xff;
int y = (r*19661+g*38666+b*7209 + 32829)>>16;
return y << 24;
}
| DoS Exec Code Overflow | 0 | static uint32_t luminocity(uint32_t x)
{
int r = (x >> 16) & 0xff;
int g = (x >> 8) & 0xff;
int b = (x >> 0) & 0xff;
int y = (r*19661+g*38666+b*7209 + 32829)>>16;
return y << 24;
}
| @@ -16,7 +16,7 @@
//
// Copyright (C) 2005-2008 Jeff Muizelaar <jeff@infidigm.net>
// Copyright (C) 2005, 2006 Kristian Høgsberg <krh@redhat.com>
-// Copyright (C) 2005 Albert Astals Cid <aacid@kde.org>
+// Copyright (C) 2005, 2009 Albert Astals Cid <aacid@kde.org>
// Copyright (C) 2005 Nickolay V. Shmyrev <nshmyre... | CWE-189 | null | null |
719 | void CairoOutputDev::paintTransparencyGroup(GfxState * /*state*/, double * /*bbox*/) {
cairo_set_source (cairo, group);
if (!mask) {
if (shape) {
cairo_save (cairo);
/* OPERATOR_SOURCE w/ a mask is defined as (src IN mask) ADD (dest OUT mask)
* however our source has already been clipped to... | DoS Exec Code Overflow | 0 | void CairoOutputDev::paintTransparencyGroup(GfxState * /*state*/, double * /*bbox*/) {
cairo_set_source (cairo, group);
if (!mask) {
if (shape) {
cairo_save (cairo);
/* OPERATOR_SOURCE w/ a mask is defined as (src IN mask) ADD (dest OUT mask)
* however our source has already been clipped to... | @@ -16,7 +16,7 @@
//
// Copyright (C) 2005-2008 Jeff Muizelaar <jeff@infidigm.net>
// Copyright (C) 2005, 2006 Kristian Høgsberg <krh@redhat.com>
-// Copyright (C) 2005 Albert Astals Cid <aacid@kde.org>
+// Copyright (C) 2005, 2009 Albert Astals Cid <aacid@kde.org>
// Copyright (C) 2005 Nickolay V. Shmyrev <nshmyre... | CWE-189 | null | null |
720 | void CairoImageOutputDev::saveImage(CairoImage *image)
{
if (numImages >= size) {
size += 16;
images = (CairoImage **) greallocn (images, size, sizeof (CairoImage *));
}
images[numImages++] = image;
}
| DoS Exec Code Overflow | 0 | void CairoImageOutputDev::saveImage(CairoImage *image)
{
if (numImages >= size) {
size += 16;
images = (CairoImage **) greallocn (images, size, sizeof (CairoImage *));
}
images[numImages++] = image;
}
| @@ -16,7 +16,7 @@
//
// Copyright (C) 2005-2008 Jeff Muizelaar <jeff@infidigm.net>
// Copyright (C) 2005, 2006 Kristian Høgsberg <krh@redhat.com>
-// Copyright (C) 2005 Albert Astals Cid <aacid@kde.org>
+// Copyright (C) 2005, 2009 Albert Astals Cid <aacid@kde.org>
// Copyright (C) 2005 Nickolay V. Shmyrev <nshmyre... | CWE-189 | null | null |
721 | void CairoOutputDev::saveState(GfxState *state) {
LOG(printf ("save\n"));
cairo_save (cairo);
if (cairo_shape)
cairo_save (cairo_shape);
MaskStack *ms = new MaskStack;
ms->mask = cairo_pattern_reference(mask);
ms->next = maskStack;
maskStack = ms;
}
| DoS Exec Code Overflow | 0 | void CairoOutputDev::saveState(GfxState *state) {
LOG(printf ("save\n"));
cairo_save (cairo);
if (cairo_shape)
cairo_save (cairo_shape);
MaskStack *ms = new MaskStack;
ms->mask = cairo_pattern_reference(mask);
ms->next = maskStack;
maskStack = ms;
}
| @@ -16,7 +16,7 @@
//
// Copyright (C) 2005-2008 Jeff Muizelaar <jeff@infidigm.net>
// Copyright (C) 2005, 2006 Kristian Høgsberg <krh@redhat.com>
-// Copyright (C) 2005 Albert Astals Cid <aacid@kde.org>
+// Copyright (C) 2005, 2009 Albert Astals Cid <aacid@kde.org>
// Copyright (C) 2005 Nickolay V. Shmyrev <nshmyre... | CWE-189 | null | null |
722 | void CairoOutputDev::setCairo(cairo_t *cairo)
{
if (this->cairo != NULL) {
cairo_status_t status = cairo_status (this->cairo);
if (status) {
warning("cairo context error: %s\n", cairo_status_to_string(status));
}
cairo_destroy (this->cairo);
assert(!cairo_shape);
}
if (cairo != NULL) {
... | DoS Exec Code Overflow | 0 | void CairoOutputDev::setCairo(cairo_t *cairo)
{
if (this->cairo != NULL) {
cairo_status_t status = cairo_status (this->cairo);
if (status) {
warning("cairo context error: %s\n", cairo_status_to_string(status));
}
cairo_destroy (this->cairo);
assert(!cairo_shape);
}
if (cairo != NULL) {
... | @@ -16,7 +16,7 @@
//
// Copyright (C) 2005-2008 Jeff Muizelaar <jeff@infidigm.net>
// Copyright (C) 2005, 2006 Kristian Høgsberg <krh@redhat.com>
-// Copyright (C) 2005 Albert Astals Cid <aacid@kde.org>
+// Copyright (C) 2005, 2009 Albert Astals Cid <aacid@kde.org>
// Copyright (C) 2005 Nickolay V. Shmyrev <nshmyre... | CWE-189 | null | null |
723 | void CairoOutputDev::setDefaultCTM(double *ctm) {
cairo_matrix_t matrix;
matrix.xx = ctm[0];
matrix.yx = ctm[1];
matrix.xy = ctm[2];
matrix.yy = ctm[3];
matrix.x0 = ctm[4];
matrix.y0 = ctm[5];
cairo_transform (cairo, &matrix);
if (cairo_shape)
cairo_transform (cairo_shape, &matrix);
OutputDe... | DoS Exec Code Overflow | 0 | void CairoOutputDev::setDefaultCTM(double *ctm) {
cairo_matrix_t matrix;
matrix.xx = ctm[0];
matrix.yx = ctm[1];
matrix.xy = ctm[2];
matrix.yy = ctm[3];
matrix.x0 = ctm[4];
matrix.y0 = ctm[5];
cairo_transform (cairo, &matrix);
if (cairo_shape)
cairo_transform (cairo_shape, &matrix);
OutputDe... | @@ -16,7 +16,7 @@
//
// Copyright (C) 2005-2008 Jeff Muizelaar <jeff@infidigm.net>
// Copyright (C) 2005, 2006 Kristian Høgsberg <krh@redhat.com>
-// Copyright (C) 2005 Albert Astals Cid <aacid@kde.org>
+// Copyright (C) 2005, 2009 Albert Astals Cid <aacid@kde.org>
// Copyright (C) 2005 Nickolay V. Shmyrev <nshmyre... | CWE-189 | null | null |
724 | void CairoImage::setImage (cairo_surface_t *image) {
if (this->image)
cairo_surface_destroy (this->image);
this->image = cairo_surface_reference (image);
}
| DoS Exec Code Overflow | 0 | void CairoImage::setImage (cairo_surface_t *image) {
if (this->image)
cairo_surface_destroy (this->image);
this->image = cairo_surface_reference (image);
}
| @@ -16,7 +16,7 @@
//
// Copyright (C) 2005-2008 Jeff Muizelaar <jeff@infidigm.net>
// Copyright (C) 2005, 2006 Kristian Høgsberg <krh@redhat.com>
-// Copyright (C) 2005 Albert Astals Cid <aacid@kde.org>
+// Copyright (C) 2005, 2009 Albert Astals Cid <aacid@kde.org>
// Copyright (C) 2005 Nickolay V. Shmyrev <nshmyre... | CWE-189 | null | null |
725 | static inline int splashFloor(SplashCoord x) {
return (int)floor(x);
}
| DoS Exec Code Overflow | 0 | static inline int splashFloor(SplashCoord x) {
return (int)floor(x);
}
| @@ -16,7 +16,7 @@
//
// Copyright (C) 2005-2008 Jeff Muizelaar <jeff@infidigm.net>
// Copyright (C) 2005, 2006 Kristian Høgsberg <krh@redhat.com>
-// Copyright (C) 2005 Albert Astals Cid <aacid@kde.org>
+// Copyright (C) 2005, 2009 Albert Astals Cid <aacid@kde.org>
// Copyright (C) 2005 Nickolay V. Shmyrev <nshmyre... | CWE-189 | null | null |
726 | static inline int splashRound(SplashCoord x) {
return (int)floor(x + 0.5);
}
| DoS Exec Code Overflow | 0 | static inline int splashRound(SplashCoord x) {
return (int)floor(x + 0.5);
}
| @@ -16,7 +16,7 @@
//
// Copyright (C) 2005-2008 Jeff Muizelaar <jeff@infidigm.net>
// Copyright (C) 2005, 2006 Kristian Høgsberg <krh@redhat.com>
-// Copyright (C) 2005 Albert Astals Cid <aacid@kde.org>
+// Copyright (C) 2005, 2009 Albert Astals Cid <aacid@kde.org>
// Copyright (C) 2005 Nickolay V. Shmyrev <nshmyre... | CWE-189 | null | null |
727 | void CairoOutputDev::startDoc(XRef *xrefA, Catalog *catalogA,
CairoFontEngine *parentFontEngine) {
xref = xrefA;
catalog = catalogA;
if (parentFontEngine) {
fontEngine = parentFontEngine;
} else {
if (fontEngine) {
delete fontEngine;
}
fontEngine = new CairoFontEngine(ft_lib);
... | DoS Exec Code Overflow | 0 | void CairoOutputDev::startDoc(XRef *xrefA, Catalog *catalogA,
CairoFontEngine *parentFontEngine) {
xref = xrefA;
catalog = catalogA;
if (parentFontEngine) {
fontEngine = parentFontEngine;
} else {
if (fontEngine) {
delete fontEngine;
}
fontEngine = new CairoFontEngine(ft_lib);
... | @@ -16,7 +16,7 @@
//
// Copyright (C) 2005-2008 Jeff Muizelaar <jeff@infidigm.net>
// Copyright (C) 2005, 2006 Kristian Høgsberg <krh@redhat.com>
-// Copyright (C) 2005 Albert Astals Cid <aacid@kde.org>
+// Copyright (C) 2005, 2009 Albert Astals Cid <aacid@kde.org>
// Copyright (C) 2005 Nickolay V. Shmyrev <nshmyre... | CWE-189 | null | null |
728 | void CairoOutputDev::startPage(int pageNum, GfxState *state) {
/* set up some per page defaults */
cairo_pattern_destroy(fill_pattern);
fill_pattern = cairo_pattern_create_rgb(0., 0., 0.);
cairo_pattern_destroy(stroke_pattern);
stroke_pattern = cairo_pattern_create_rgb(0., 0., 0.);
if (text)
text->sta... | DoS Exec Code Overflow | 0 | void CairoOutputDev::startPage(int pageNum, GfxState *state) {
/* set up some per page defaults */
cairo_pattern_destroy(fill_pattern);
fill_pattern = cairo_pattern_create_rgb(0., 0., 0.);
cairo_pattern_destroy(stroke_pattern);
stroke_pattern = cairo_pattern_create_rgb(0., 0., 0.);
if (text)
text->sta... | @@ -16,7 +16,7 @@
//
// Copyright (C) 2005-2008 Jeff Muizelaar <jeff@infidigm.net>
// Copyright (C) 2005, 2006 Kristian Høgsberg <krh@redhat.com>
-// Copyright (C) 2005 Albert Astals Cid <aacid@kde.org>
+// Copyright (C) 2005, 2009 Albert Astals Cid <aacid@kde.org>
// Copyright (C) 2005 Nickolay V. Shmyrev <nshmyre... | CWE-189 | null | null |
729 | void CairoOutputDev::stroke(GfxState *state) {
doPath (cairo, state, state->getPath());
cairo_set_source (cairo, stroke_pattern);
LOG(printf ("stroke\n"));
cairo_stroke (cairo);
if (cairo_shape) {
doPath (cairo_shape, state, state->getPath());
cairo_stroke (cairo_shape);
}
}
| DoS Exec Code Overflow | 0 | void CairoOutputDev::stroke(GfxState *state) {
doPath (cairo, state, state->getPath());
cairo_set_source (cairo, stroke_pattern);
LOG(printf ("stroke\n"));
cairo_stroke (cairo);
if (cairo_shape) {
doPath (cairo_shape, state, state->getPath());
cairo_stroke (cairo_shape);
}
}
| @@ -16,7 +16,7 @@
//
// Copyright (C) 2005-2008 Jeff Muizelaar <jeff@infidigm.net>
// Copyright (C) 2005, 2006 Kristian Høgsberg <krh@redhat.com>
-// Copyright (C) 2005 Albert Astals Cid <aacid@kde.org>
+// Copyright (C) 2005, 2009 Albert Astals Cid <aacid@kde.org>
// Copyright (C) 2005 Nickolay V. Shmyrev <nshmyre... | CWE-189 | null | null |
730 | void CairoOutputDev::type3D1(GfxState *state, double wx, double wy,
double llx, double lly, double urx, double ury) {
t3_glyph_wx = wx;
t3_glyph_wy = wy;
t3_glyph_bbox[0] = llx;
t3_glyph_bbox[1] = lly;
t3_glyph_bbox[2] = urx;
t3_glyph_bbox[3] = ury;
t3_glyph_has_bbox = gTrue;
}
| DoS Exec Code Overflow | 0 | void CairoOutputDev::type3D1(GfxState *state, double wx, double wy,
double llx, double lly, double urx, double ury) {
t3_glyph_wx = wx;
t3_glyph_wy = wy;
t3_glyph_bbox[0] = llx;
t3_glyph_bbox[1] = lly;
t3_glyph_bbox[2] = urx;
t3_glyph_bbox[3] = ury;
t3_glyph_has_bbox = gTrue;
}
| @@ -16,7 +16,7 @@
//
// Copyright (C) 2005-2008 Jeff Muizelaar <jeff@infidigm.net>
// Copyright (C) 2005, 2006 Kristian Høgsberg <krh@redhat.com>
-// Copyright (C) 2005 Albert Astals Cid <aacid@kde.org>
+// Copyright (C) 2005, 2009 Albert Astals Cid <aacid@kde.org>
// Copyright (C) 2005 Nickolay V. Shmyrev <nshmyre... | CWE-189 | null | null |
731 | void CairoOutputDev::updateAll(GfxState *state) {
updateLineDash(state);
updateLineJoin(state);
updateLineCap(state);
updateLineWidth(state);
updateFlatness(state);
updateMiterLimit(state);
updateFillColor(state);
updateStrokeColor(state);
updateFillOpacity(state);
updateStrokeOpacity(state);
need... | DoS Exec Code Overflow | 0 | void CairoOutputDev::updateAll(GfxState *state) {
updateLineDash(state);
updateLineJoin(state);
updateLineCap(state);
updateLineWidth(state);
updateFlatness(state);
updateMiterLimit(state);
updateFillColor(state);
updateStrokeColor(state);
updateFillOpacity(state);
updateStrokeOpacity(state);
need... | @@ -16,7 +16,7 @@
//
// Copyright (C) 2005-2008 Jeff Muizelaar <jeff@infidigm.net>
// Copyright (C) 2005, 2006 Kristian Høgsberg <krh@redhat.com>
-// Copyright (C) 2005 Albert Astals Cid <aacid@kde.org>
+// Copyright (C) 2005, 2009 Albert Astals Cid <aacid@kde.org>
// Copyright (C) 2005 Nickolay V. Shmyrev <nshmyre... | CWE-189 | null | null |
732 | void CairoOutputDev::updateFillColor(GfxState *state) {
state->getFillRGB(&fill_color);
cairo_pattern_destroy(fill_pattern);
fill_pattern = cairo_pattern_create_rgba(fill_color.r / 65535.0,
fill_color.g / 65535.0,
fill_color.b / 65535.0,
fill_opacity);
LOG(printf ("fill color: %d %d %d... | DoS Exec Code Overflow | 0 | void CairoOutputDev::updateFillColor(GfxState *state) {
state->getFillRGB(&fill_color);
cairo_pattern_destroy(fill_pattern);
fill_pattern = cairo_pattern_create_rgba(fill_color.r / 65535.0,
fill_color.g / 65535.0,
fill_color.b / 65535.0,
fill_opacity);
LOG(printf ("fill color: %d %d %d... | @@ -16,7 +16,7 @@
//
// Copyright (C) 2005-2008 Jeff Muizelaar <jeff@infidigm.net>
// Copyright (C) 2005, 2006 Kristian Høgsberg <krh@redhat.com>
-// Copyright (C) 2005 Albert Astals Cid <aacid@kde.org>
+// Copyright (C) 2005, 2009 Albert Astals Cid <aacid@kde.org>
// Copyright (C) 2005 Nickolay V. Shmyrev <nshmyre... | CWE-189 | null | null |
733 | void CairoOutputDev::updateFlatness(GfxState *state) {
}
| DoS Exec Code Overflow | 0 | void CairoOutputDev::updateFlatness(GfxState *state) {
}
| @@ -16,7 +16,7 @@
//
// Copyright (C) 2005-2008 Jeff Muizelaar <jeff@infidigm.net>
// Copyright (C) 2005, 2006 Kristian Høgsberg <krh@redhat.com>
-// Copyright (C) 2005 Albert Astals Cid <aacid@kde.org>
+// Copyright (C) 2005, 2009 Albert Astals Cid <aacid@kde.org>
// Copyright (C) 2005 Nickolay V. Shmyrev <nshmyre... | CWE-189 | null | null |
734 | void CairoOutputDev::updateLineCap(GfxState *state) {
switch (state->getLineCap()) {
case 0:
cairo_set_line_cap (cairo, CAIRO_LINE_CAP_BUTT);
break;
case 1:
cairo_set_line_cap (cairo, CAIRO_LINE_CAP_ROUND);
break;
case 2:
cairo_set_line_cap (cairo, CAIRO_LINE_CAP_SQUARE);
break;
}
if... | DoS Exec Code Overflow | 0 | void CairoOutputDev::updateLineCap(GfxState *state) {
switch (state->getLineCap()) {
case 0:
cairo_set_line_cap (cairo, CAIRO_LINE_CAP_BUTT);
break;
case 1:
cairo_set_line_cap (cairo, CAIRO_LINE_CAP_ROUND);
break;
case 2:
cairo_set_line_cap (cairo, CAIRO_LINE_CAP_SQUARE);
break;
}
if... | @@ -16,7 +16,7 @@
//
// Copyright (C) 2005-2008 Jeff Muizelaar <jeff@infidigm.net>
// Copyright (C) 2005, 2006 Kristian Høgsberg <krh@redhat.com>
-// Copyright (C) 2005 Albert Astals Cid <aacid@kde.org>
+// Copyright (C) 2005, 2009 Albert Astals Cid <aacid@kde.org>
// Copyright (C) 2005 Nickolay V. Shmyrev <nshmyre... | CWE-189 | null | null |
735 | void CairoOutputDev::updateLineDash(GfxState *state) {
double *dashPattern;
int dashLength;
double dashStart;
state->getLineDash(&dashPattern, &dashLength, &dashStart);
cairo_set_dash (cairo, dashPattern, dashLength, dashStart);
if (cairo_shape)
cairo_set_dash (cairo_shape, dashPattern, dashLength, das... | DoS Exec Code Overflow | 0 | void CairoOutputDev::updateLineDash(GfxState *state) {
double *dashPattern;
int dashLength;
double dashStart;
state->getLineDash(&dashPattern, &dashLength, &dashStart);
cairo_set_dash (cairo, dashPattern, dashLength, dashStart);
if (cairo_shape)
cairo_set_dash (cairo_shape, dashPattern, dashLength, das... | @@ -16,7 +16,7 @@
//
// Copyright (C) 2005-2008 Jeff Muizelaar <jeff@infidigm.net>
// Copyright (C) 2005, 2006 Kristian Høgsberg <krh@redhat.com>
-// Copyright (C) 2005 Albert Astals Cid <aacid@kde.org>
+// Copyright (C) 2005, 2009 Albert Astals Cid <aacid@kde.org>
// Copyright (C) 2005 Nickolay V. Shmyrev <nshmyre... | CWE-189 | null | null |
736 | void CairoOutputDev::updateLineJoin(GfxState *state) {
switch (state->getLineJoin()) {
case 0:
cairo_set_line_join (cairo, CAIRO_LINE_JOIN_MITER);
break;
case 1:
cairo_set_line_join (cairo, CAIRO_LINE_JOIN_ROUND);
break;
case 2:
cairo_set_line_join (cairo, CAIRO_LINE_JOIN_BEVEL);
break;
... | DoS Exec Code Overflow | 0 | void CairoOutputDev::updateLineJoin(GfxState *state) {
switch (state->getLineJoin()) {
case 0:
cairo_set_line_join (cairo, CAIRO_LINE_JOIN_MITER);
break;
case 1:
cairo_set_line_join (cairo, CAIRO_LINE_JOIN_ROUND);
break;
case 2:
cairo_set_line_join (cairo, CAIRO_LINE_JOIN_BEVEL);
break;
... | @@ -16,7 +16,7 @@
//
// Copyright (C) 2005-2008 Jeff Muizelaar <jeff@infidigm.net>
// Copyright (C) 2005, 2006 Kristian Høgsberg <krh@redhat.com>
-// Copyright (C) 2005 Albert Astals Cid <aacid@kde.org>
+// Copyright (C) 2005, 2009 Albert Astals Cid <aacid@kde.org>
// Copyright (C) 2005 Nickolay V. Shmyrev <nshmyre... | CWE-189 | null | null |
737 | void CairoOutputDev::updateMiterLimit(GfxState *state) {
cairo_set_miter_limit (cairo, state->getMiterLimit());
if (cairo_shape)
cairo_set_miter_limit (cairo_shape, state->getMiterLimit());
}
| DoS Exec Code Overflow | 0 | void CairoOutputDev::updateMiterLimit(GfxState *state) {
cairo_set_miter_limit (cairo, state->getMiterLimit());
if (cairo_shape)
cairo_set_miter_limit (cairo_shape, state->getMiterLimit());
}
| @@ -16,7 +16,7 @@
//
// Copyright (C) 2005-2008 Jeff Muizelaar <jeff@infidigm.net>
// Copyright (C) 2005, 2006 Kristian Høgsberg <krh@redhat.com>
-// Copyright (C) 2005 Albert Astals Cid <aacid@kde.org>
+// Copyright (C) 2005, 2009 Albert Astals Cid <aacid@kde.org>
// Copyright (C) 2005 Nickolay V. Shmyrev <nshmyre... | CWE-189 | null | null |
738 | void CairoOutputDev::updateStrokeColor(GfxState *state) {
state->getStrokeRGB(&stroke_color);
cairo_pattern_destroy(stroke_pattern);
stroke_pattern = cairo_pattern_create_rgba(stroke_color.r / 65535.0,
stroke_color.g / 65535.0,
stroke_color.b / 65535.0,
stroke_opacity);
LOG(pri... | DoS Exec Code Overflow | 0 | void CairoOutputDev::updateStrokeColor(GfxState *state) {
state->getStrokeRGB(&stroke_color);
cairo_pattern_destroy(stroke_pattern);
stroke_pattern = cairo_pattern_create_rgba(stroke_color.r / 65535.0,
stroke_color.g / 65535.0,
stroke_color.b / 65535.0,
stroke_opacity);
LOG(pri... | @@ -16,7 +16,7 @@
//
// Copyright (C) 2005-2008 Jeff Muizelaar <jeff@infidigm.net>
// Copyright (C) 2005, 2006 Kristian Høgsberg <krh@redhat.com>
-// Copyright (C) 2005 Albert Astals Cid <aacid@kde.org>
+// Copyright (C) 2005, 2009 Albert Astals Cid <aacid@kde.org>
// Copyright (C) 2005 Nickolay V. Shmyrev <nshmyre... | CWE-189 | null | null |
739 | CairoImage::~CairoImage () {
if (image)
cairo_surface_destroy (image);
}
| DoS Exec Code Overflow | 0 | CairoImage::~CairoImage () {
if (image)
cairo_surface_destroy (image);
}
| @@ -16,7 +16,7 @@
//
// Copyright (C) 2005-2008 Jeff Muizelaar <jeff@infidigm.net>
// Copyright (C) 2005, 2006 Kristian Høgsberg <krh@redhat.com>
-// Copyright (C) 2005 Albert Astals Cid <aacid@kde.org>
+// Copyright (C) 2005, 2009 Albert Astals Cid <aacid@kde.org>
// Copyright (C) 2005 Nickolay V. Shmyrev <nshmyre... | CWE-189 | null | null |
740 | CairoImageOutputDev::~CairoImageOutputDev()
{
int i;
for (i = 0; i < numImages; i++)
delete images[i];
gfree (images);
}
| DoS Exec Code Overflow | 0 | CairoImageOutputDev::~CairoImageOutputDev()
{
int i;
for (i = 0; i < numImages; i++)
delete images[i];
gfree (images);
}
| @@ -16,7 +16,7 @@
//
// Copyright (C) 2005-2008 Jeff Muizelaar <jeff@infidigm.net>
// Copyright (C) 2005, 2006 Kristian Høgsberg <krh@redhat.com>
-// Copyright (C) 2005 Albert Astals Cid <aacid@kde.org>
+// Copyright (C) 2005, 2009 Albert Astals Cid <aacid@kde.org>
// Copyright (C) 2005 Nickolay V. Shmyrev <nshmyre... | CWE-189 | null | null |
741 | CairoOutputDev::~CairoOutputDev() {
if (fontEngine_owner && fontEngine) {
delete fontEngine;
}
if (cairo)
cairo_destroy (cairo);
cairo_pattern_destroy (stroke_pattern);
cairo_pattern_destroy (fill_pattern);
if (group)
cairo_pattern_destroy (group);
if (mask)
cairo_pattern_destroy (mask);
... | DoS Exec Code Overflow | 0 | CairoOutputDev::~CairoOutputDev() {
if (fontEngine_owner && fontEngine) {
delete fontEngine;
}
if (cairo)
cairo_destroy (cairo);
cairo_pattern_destroy (stroke_pattern);
cairo_pattern_destroy (fill_pattern);
if (group)
cairo_pattern_destroy (group);
if (mask)
cairo_pattern_destroy (mask);
... | @@ -16,7 +16,7 @@
//
// Copyright (C) 2005-2008 Jeff Muizelaar <jeff@infidigm.net>
// Copyright (C) 2005, 2006 Kristian Høgsberg <krh@redhat.com>
-// Copyright (C) 2005 Albert Astals Cid <aacid@kde.org>
+// Copyright (C) 2005, 2009 Albert Astals Cid <aacid@kde.org>
// Copyright (C) 2005 Nickolay V. Shmyrev <nshmyre... | CWE-189 | null | null |
742 | static int CMSError(int ecode, const char *msg)
{
error(-1,const_cast<char *>(msg));
return 1;
}
| DoS Exec Code Overflow | 0 | static int CMSError(int ecode, const char *msg)
{
error(-1,const_cast<char *>(msg));
return 1;
}
| @@ -1849,7 +1849,7 @@ void GfxIndexedColorSpace::getRGBLine(Guchar *in, unsigned int *out, int length)
int i, j, n;
n = base->getNComps();
- line = (Guchar *) gmalloc (length * n);
+ line = (Guchar *) gmallocn (length, n);
for (i = 0; i < length; i++)
for (j = 0; j < n; j++)
line[i * n + j] = l... | CWE-189 | null | null |
743 | GfxAxialShading::GfxAxialShading(double x0A, double y0A,
double x1A, double y1A,
double t0A, double t1A,
Function **funcsA, int nFuncsA,
GBool extend0A, GBool extend1A):
GfxShading(2)
{
int i;
x0 = x0A;
y0 = y0A;
x1 = x1A;
y1 = y1A;
t0 = t0A;
t1 = t1A;
nFuncs = nFuncsA;
for (i =... | DoS Exec Code Overflow | 0 | GfxAxialShading::GfxAxialShading(double x0A, double y0A,
double x1A, double y1A,
double t0A, double t1A,
Function **funcsA, int nFuncsA,
GBool extend0A, GBool extend1A):
GfxShading(2)
{
int i;
x0 = x0A;
y0 = y0A;
x1 = x1A;
y1 = y1A;
t0 = t0A;
t1 = t1A;
nFuncs = nFuncsA;
for (i =... | @@ -1849,7 +1849,7 @@ void GfxIndexedColorSpace::getRGBLine(Guchar *in, unsigned int *out, int length)
int i, j, n;
n = base->getNComps();
- line = (Guchar *) gmalloc (length * n);
+ line = (Guchar *) gmallocn (length, n);
for (i = 0; i < length; i++)
for (j = 0; j < n; j++)
line[i * n + j] = l... | CWE-189 | null | null |
744 | GfxCalGrayColorSpace::GfxCalGrayColorSpace() {
whiteX = whiteY = whiteZ = 1;
blackX = blackY = blackZ = 0;
gamma = 1;
}
| DoS Exec Code Overflow | 0 | GfxCalGrayColorSpace::GfxCalGrayColorSpace() {
whiteX = whiteY = whiteZ = 1;
blackX = blackY = blackZ = 0;
gamma = 1;
}
| @@ -1849,7 +1849,7 @@ void GfxIndexedColorSpace::getRGBLine(Guchar *in, unsigned int *out, int length)
int i, j, n;
n = base->getNComps();
- line = (Guchar *) gmalloc (length * n);
+ line = (Guchar *) gmallocn (length, n);
for (i = 0; i < length; i++)
for (j = 0; j < n; j++)
line[i * n + j] = l... | CWE-189 | null | null |
745 | GfxCalRGBColorSpace::GfxCalRGBColorSpace() {
whiteX = whiteY = whiteZ = 1;
blackX = blackY = blackZ = 0;
gammaR = gammaG = gammaB = 1;
mat[0] = 1; mat[1] = 0; mat[2] = 0;
mat[3] = 0; mat[4] = 1; mat[5] = 0;
mat[6] = 0; mat[7] = 0; mat[8] = 1;
}
| DoS Exec Code Overflow | 0 | GfxCalRGBColorSpace::GfxCalRGBColorSpace() {
whiteX = whiteY = whiteZ = 1;
blackX = blackY = blackZ = 0;
gammaR = gammaG = gammaB = 1;
mat[0] = 1; mat[1] = 0; mat[2] = 0;
mat[3] = 0; mat[4] = 1; mat[5] = 0;
mat[6] = 0; mat[7] = 0; mat[8] = 1;
}
| @@ -1849,7 +1849,7 @@ void GfxIndexedColorSpace::getRGBLine(Guchar *in, unsigned int *out, int length)
int i, j, n;
n = base->getNComps();
- line = (Guchar *) gmalloc (length * n);
+ line = (Guchar *) gmallocn (length, n);
for (i = 0; i < length; i++)
for (j = 0; j < n; j++)
line[i * n + j] = l... | CWE-189 | null | null |
746 | GfxColorSpace::GfxColorSpace() {
}
| DoS Exec Code Overflow | 0 | GfxColorSpace::GfxColorSpace() {
}
| @@ -1849,7 +1849,7 @@ void GfxIndexedColorSpace::getRGBLine(Guchar *in, unsigned int *out, int length)
int i, j, n;
n = base->getNComps();
- line = (Guchar *) gmalloc (length * n);
+ line = (Guchar *) gmallocn (length, n);
for (i = 0; i < length; i++)
for (j = 0; j < n; j++)
line[i * n + j] = l... | CWE-189 | null | null |
747 | GfxDeviceCMYKColorSpace::GfxDeviceCMYKColorSpace() {
}
| DoS Exec Code Overflow | 0 | GfxDeviceCMYKColorSpace::GfxDeviceCMYKColorSpace() {
}
| @@ -1849,7 +1849,7 @@ void GfxIndexedColorSpace::getRGBLine(Guchar *in, unsigned int *out, int length)
int i, j, n;
n = base->getNComps();
- line = (Guchar *) gmalloc (length * n);
+ line = (Guchar *) gmallocn (length, n);
for (i = 0; i < length; i++)
for (j = 0; j < n; j++)
line[i * n + j] = l... | CWE-189 | null | null |
748 | GfxDeviceGrayColorSpace::GfxDeviceGrayColorSpace() {
}
| DoS Exec Code Overflow | 0 | GfxDeviceGrayColorSpace::GfxDeviceGrayColorSpace() {
}
| @@ -1849,7 +1849,7 @@ void GfxIndexedColorSpace::getRGBLine(Guchar *in, unsigned int *out, int length)
int i, j, n;
n = base->getNComps();
- line = (Guchar *) gmalloc (length * n);
+ line = (Guchar *) gmallocn (length, n);
for (i = 0; i < length; i++)
for (j = 0; j < n; j++)
line[i * n + j] = l... | CWE-189 | null | null |
749 | GfxDeviceNColorSpace::GfxDeviceNColorSpace(int nCompsA,
GfxColorSpace *altA,
Function *funcA) {
nComps = nCompsA;
alt = altA;
func = funcA;
nonMarking = gFalse;
}
| DoS Exec Code Overflow | 0 | GfxDeviceNColorSpace::GfxDeviceNColorSpace(int nCompsA,
GfxColorSpace *altA,
Function *funcA) {
nComps = nCompsA;
alt = altA;
func = funcA;
nonMarking = gFalse;
}
| @@ -1849,7 +1849,7 @@ void GfxIndexedColorSpace::getRGBLine(Guchar *in, unsigned int *out, int length)
int i, j, n;
n = base->getNComps();
- line = (Guchar *) gmalloc (length * n);
+ line = (Guchar *) gmallocn (length, n);
for (i = 0; i < length; i++)
for (j = 0; j < n; j++)
line[i * n + j] = l... | CWE-189 | null | null |
750 | GfxDeviceRGBColorSpace::GfxDeviceRGBColorSpace() {
}
| DoS Exec Code Overflow | 0 | GfxDeviceRGBColorSpace::GfxDeviceRGBColorSpace() {
}
| @@ -1849,7 +1849,7 @@ void GfxIndexedColorSpace::getRGBLine(Guchar *in, unsigned int *out, int length)
int i, j, n;
n = base->getNComps();
- line = (Guchar *) gmalloc (length * n);
+ line = (Guchar *) gmallocn (length, n);
for (i = 0; i < length; i++)
for (j = 0; j < n; j++)
line[i * n + j] = l... | CWE-189 | null | null |
751 | GfxFunctionShading::GfxFunctionShading(double x0A, double y0A,
double x1A, double y1A,
double *matrixA,
Function **funcsA, int nFuncsA):
GfxShading(1)
{
int i;
x0 = x0A;
y0 = y0A;
x1 = x1A;
y1 = y1A;
for (i = 0; i < 6; ++i) {
matrix[i] = matrixA[i];
}
nFuncs = nFu... | DoS Exec Code Overflow | 0 | GfxFunctionShading::GfxFunctionShading(double x0A, double y0A,
double x1A, double y1A,
double *matrixA,
Function **funcsA, int nFuncsA):
GfxShading(1)
{
int i;
x0 = x0A;
y0 = y0A;
x1 = x1A;
y1 = y1A;
for (i = 0; i < 6; ++i) {
matrix[i] = matrixA[i];
}
nFuncs = nFu... | @@ -1849,7 +1849,7 @@ void GfxIndexedColorSpace::getRGBLine(Guchar *in, unsigned int *out, int length)
int i, j, n;
n = base->getNComps();
- line = (Guchar *) gmalloc (length * n);
+ line = (Guchar *) gmallocn (length, n);
for (i = 0; i < length; i++)
for (j = 0; j < n; j++)
line[i * n + j] = l... | CWE-189 | null | null |
752 | GfxFunctionShading::GfxFunctionShading(GfxFunctionShading *shading):
GfxShading(shading)
{
int i;
x0 = shading->x0;
y0 = shading->y0;
x1 = shading->x1;
y1 = shading->y1;
for (i = 0; i < 6; ++i) {
matrix[i] = shading->matrix[i];
}
nFuncs = shading->nFuncs;
for (i = 0; i < nFuncs; ++i) {
func... | DoS Exec Code Overflow | 0 | GfxFunctionShading::GfxFunctionShading(GfxFunctionShading *shading):
GfxShading(shading)
{
int i;
x0 = shading->x0;
y0 = shading->y0;
x1 = shading->x1;
y1 = shading->y1;
for (i = 0; i < 6; ++i) {
matrix[i] = shading->matrix[i];
}
nFuncs = shading->nFuncs;
for (i = 0; i < nFuncs; ++i) {
func... | @@ -1849,7 +1849,7 @@ void GfxIndexedColorSpace::getRGBLine(Guchar *in, unsigned int *out, int length)
int i, j, n;
n = base->getNComps();
- line = (Guchar *) gmalloc (length * n);
+ line = (Guchar *) gmallocn (length, n);
for (i = 0; i < length; i++)
for (j = 0; j < n; j++)
line[i * n + j] = l... | CWE-189 | null | null |
753 | GfxGouraudTriangleShading::GfxGouraudTriangleShading(
int typeA,
GfxGouraudVertex *verticesA, int nVerticesA,
int (*trianglesA)[3], int nTrianglesA,
Function **funcsA, int nFuncsA):
GfxShading(typeA)
{
int i;
vertices = verticesA;
nVertices = nVerticesA;
triangles = tr... | DoS Exec Code Overflow | 0 | GfxGouraudTriangleShading::GfxGouraudTriangleShading(
int typeA,
GfxGouraudVertex *verticesA, int nVerticesA,
int (*trianglesA)[3], int nTrianglesA,
Function **funcsA, int nFuncsA):
GfxShading(typeA)
{
int i;
vertices = verticesA;
nVertices = nVerticesA;
triangles = tr... | @@ -1849,7 +1849,7 @@ void GfxIndexedColorSpace::getRGBLine(Guchar *in, unsigned int *out, int length)
int i, j, n;
n = base->getNComps();
- line = (Guchar *) gmalloc (length * n);
+ line = (Guchar *) gmallocn (length, n);
for (i = 0; i < length; i++)
for (j = 0; j < n; j++)
line[i * n + j] = l... | CWE-189 | null | null |
754 | GfxGouraudTriangleShading::GfxGouraudTriangleShading(
GfxGouraudTriangleShading *shading):
GfxShading(shading)
{
int i;
nVertices = shading->nVertices;
vertices = (GfxGouraudVertex *)gmallocn(nVertices, sizeof(GfxGouraudVertex));
memcpy(vertices, shading->vertices, nVertices * sizeof(GfxGouraudVert... | DoS Exec Code Overflow | 0 | GfxGouraudTriangleShading::GfxGouraudTriangleShading(
GfxGouraudTriangleShading *shading):
GfxShading(shading)
{
int i;
nVertices = shading->nVertices;
vertices = (GfxGouraudVertex *)gmallocn(nVertices, sizeof(GfxGouraudVertex));
memcpy(vertices, shading->vertices, nVertices * sizeof(GfxGouraudVert... | @@ -1849,7 +1849,7 @@ void GfxIndexedColorSpace::getRGBLine(Guchar *in, unsigned int *out, int length)
int i, j, n;
n = base->getNComps();
- line = (Guchar *) gmalloc (length * n);
+ line = (Guchar *) gmallocn (length, n);
for (i = 0; i < length; i++)
for (j = 0; j < n; j++)
line[i * n + j] = l... | CWE-189 | null | null |
755 | GfxICCBasedCache::GfxICCBasedCache()
{
num = 0;
gen = 0;
colorSpace = 0;
}
| DoS Exec Code Overflow | 0 | GfxICCBasedCache::GfxICCBasedCache()
{
num = 0;
gen = 0;
colorSpace = 0;
}
| @@ -1849,7 +1849,7 @@ void GfxIndexedColorSpace::getRGBLine(Guchar *in, unsigned int *out, int length)
int i, j, n;
n = base->getNComps();
- line = (Guchar *) gmalloc (length * n);
+ line = (Guchar *) gmallocn (length, n);
for (i = 0; i < length; i++)
for (j = 0; j < n; j++)
line[i * n + j] = l... | CWE-189 | null | null |
756 | GfxICCBasedColorSpace::GfxICCBasedColorSpace(int nCompsA, GfxColorSpace *altA,
Ref *iccProfileStreamA) {
nComps = nCompsA;
alt = altA;
iccProfileStream = *iccProfileStreamA;
rangeMin[0] = rangeMin[1] = rangeMin[2] = rangeMin[3] = 0;
rangeMax[0] = rangeMax[1] = rangeMax[2] = rangeMax[3] = 1;
#ifdef U... | DoS Exec Code Overflow | 0 | GfxICCBasedColorSpace::GfxICCBasedColorSpace(int nCompsA, GfxColorSpace *altA,
Ref *iccProfileStreamA) {
nComps = nCompsA;
alt = altA;
iccProfileStream = *iccProfileStreamA;
rangeMin[0] = rangeMin[1] = rangeMin[2] = rangeMin[3] = 0;
rangeMax[0] = rangeMax[1] = rangeMax[2] = rangeMax[3] = 1;
#ifdef U... | @@ -1849,7 +1849,7 @@ void GfxIndexedColorSpace::getRGBLine(Guchar *in, unsigned int *out, int length)
int i, j, n;
n = base->getNComps();
- line = (Guchar *) gmalloc (length * n);
+ line = (Guchar *) gmallocn (length, n);
for (i = 0; i < length; i++)
for (j = 0; j < n; j++)
line[i * n + j] = l... | CWE-189 | null | null |
757 | GfxIndexedColorSpace::GfxIndexedColorSpace(GfxColorSpace *baseA,
int indexHighA) {
base = baseA;
indexHigh = indexHighA;
lookup = (Guchar *)gmallocn((indexHigh + 1) * base->getNComps(),
sizeof(Guchar));
}
| DoS Exec Code Overflow | 0 | GfxIndexedColorSpace::GfxIndexedColorSpace(GfxColorSpace *baseA,
int indexHighA) {
base = baseA;
indexHigh = indexHighA;
lookup = (Guchar *)gmallocn((indexHigh + 1) * base->getNComps(),
sizeof(Guchar));
}
| @@ -1849,7 +1849,7 @@ void GfxIndexedColorSpace::getRGBLine(Guchar *in, unsigned int *out, int length)
int i, j, n;
n = base->getNComps();
- line = (Guchar *) gmalloc (length * n);
+ line = (Guchar *) gmallocn (length, n);
for (i = 0; i < length; i++)
for (j = 0; j < n; j++)
line[i * n + j] = l... | CWE-189 | null | null |
758 | GfxLabColorSpace::GfxLabColorSpace() {
whiteX = whiteY = whiteZ = 1;
blackX = blackY = blackZ = 0;
aMin = bMin = -100;
aMax = bMax = 100;
}
| DoS Exec Code Overflow | 0 | GfxLabColorSpace::GfxLabColorSpace() {
whiteX = whiteY = whiteZ = 1;
blackX = blackY = blackZ = 0;
aMin = bMin = -100;
aMax = bMax = 100;
}
| @@ -1849,7 +1849,7 @@ void GfxIndexedColorSpace::getRGBLine(Guchar *in, unsigned int *out, int length)
int i, j, n;
n = base->getNComps();
- line = (Guchar *) gmalloc (length * n);
+ line = (Guchar *) gmallocn (length, n);
for (i = 0; i < length; i++)
for (j = 0; j < n; j++)
line[i * n + j] = l... | CWE-189 | null | null |
759 | GfxPatchMeshShading::GfxPatchMeshShading(int typeA,
GfxPatch *patchesA, int nPatchesA,
Function **funcsA, int nFuncsA):
GfxShading(typeA)
{
int i;
patches = patchesA;
nPatches = nPatchesA;
nFuncs = nFuncsA;
for (i = 0; i < nFuncs; ++i) {
funcs[i] = funcsA[i];
}
}
| DoS Exec Code Overflow | 0 | GfxPatchMeshShading::GfxPatchMeshShading(int typeA,
GfxPatch *patchesA, int nPatchesA,
Function **funcsA, int nFuncsA):
GfxShading(typeA)
{
int i;
patches = patchesA;
nPatches = nPatchesA;
nFuncs = nFuncsA;
for (i = 0; i < nFuncs; ++i) {
funcs[i] = funcsA[i];
}
}
| @@ -1849,7 +1849,7 @@ void GfxIndexedColorSpace::getRGBLine(Guchar *in, unsigned int *out, int length)
int i, j, n;
n = base->getNComps();
- line = (Guchar *) gmalloc (length * n);
+ line = (Guchar *) gmallocn (length, n);
for (i = 0; i < length; i++)
for (j = 0; j < n; j++)
line[i * n + j] = l... | CWE-189 | null | null |
760 | GfxPatchMeshShading::GfxPatchMeshShading(GfxPatchMeshShading *shading):
GfxShading(shading)
{
int i;
nPatches = shading->nPatches;
patches = (GfxPatch *)gmallocn(nPatches, sizeof(GfxPatch));
memcpy(patches, shading->patches, nPatches * sizeof(GfxPatch));
nFuncs = shading->nFuncs;
for (i = 0; i < nFuncs; ... | DoS Exec Code Overflow | 0 | GfxPatchMeshShading::GfxPatchMeshShading(GfxPatchMeshShading *shading):
GfxShading(shading)
{
int i;
nPatches = shading->nPatches;
patches = (GfxPatch *)gmallocn(nPatches, sizeof(GfxPatch));
memcpy(patches, shading->patches, nPatches * sizeof(GfxPatch));
nFuncs = shading->nFuncs;
for (i = 0; i < nFuncs; ... | @@ -1849,7 +1849,7 @@ void GfxIndexedColorSpace::getRGBLine(Guchar *in, unsigned int *out, int length)
int i, j, n;
n = base->getNComps();
- line = (Guchar *) gmalloc (length * n);
+ line = (Guchar *) gmallocn (length, n);
for (i = 0; i < length; i++)
for (j = 0; j < n; j++)
line[i * n + j] = l... | CWE-189 | null | null |
761 | GfxPath::GfxPath() {
justMoved = gFalse;
size = 16;
n = 0;
firstX = firstY = 0;
subpaths = (GfxSubpath **)gmallocn(size, sizeof(GfxSubpath *));
}
| DoS Exec Code Overflow | 0 | GfxPath::GfxPath() {
justMoved = gFalse;
size = 16;
n = 0;
firstX = firstY = 0;
subpaths = (GfxSubpath **)gmallocn(size, sizeof(GfxSubpath *));
}
| @@ -1849,7 +1849,7 @@ void GfxIndexedColorSpace::getRGBLine(Guchar *in, unsigned int *out, int length)
int i, j, n;
n = base->getNComps();
- line = (Guchar *) gmalloc (length * n);
+ line = (Guchar *) gmallocn (length, n);
for (i = 0; i < length; i++)
for (j = 0; j < n; j++)
line[i * n + j] = l... | CWE-189 | null | null |
762 | GfxPath::GfxPath(GBool justMoved1, double firstX1, double firstY1,
GfxSubpath **subpaths1, int n1, int size1) {
int i;
justMoved = justMoved1;
firstX = firstX1;
firstY = firstY1;
size = size1;
n = n1;
subpaths = (GfxSubpath **)gmallocn(size, sizeof(GfxSubpath *));
for (i = 0; i < n; ++i)
subpath... | DoS Exec Code Overflow | 0 | GfxPath::GfxPath(GBool justMoved1, double firstX1, double firstY1,
GfxSubpath **subpaths1, int n1, int size1) {
int i;
justMoved = justMoved1;
firstX = firstX1;
firstY = firstY1;
size = size1;
n = n1;
subpaths = (GfxSubpath **)gmallocn(size, sizeof(GfxSubpath *));
for (i = 0; i < n; ++i)
subpath... | @@ -1849,7 +1849,7 @@ void GfxIndexedColorSpace::getRGBLine(Guchar *in, unsigned int *out, int length)
int i, j, n;
n = base->getNComps();
- line = (Guchar *) gmalloc (length * n);
+ line = (Guchar *) gmallocn (length, n);
for (i = 0; i < length; i++)
for (j = 0; j < n; j++)
line[i * n + j] = l... | CWE-189 | null | null |
763 | GfxPattern::GfxPattern(int typeA) {
type = typeA;
}
| DoS Exec Code Overflow | 0 | GfxPattern::GfxPattern(int typeA) {
type = typeA;
}
| @@ -1849,7 +1849,7 @@ void GfxIndexedColorSpace::getRGBLine(Guchar *in, unsigned int *out, int length)
int i, j, n;
n = base->getNComps();
- line = (Guchar *) gmalloc (length * n);
+ line = (Guchar *) gmallocn (length, n);
for (i = 0; i < length; i++)
for (j = 0; j < n; j++)
line[i * n + j] = l... | CWE-189 | null | null |
764 | GfxPatternColorSpace::GfxPatternColorSpace(GfxColorSpace *underA) {
under = underA;
}
| DoS Exec Code Overflow | 0 | GfxPatternColorSpace::GfxPatternColorSpace(GfxColorSpace *underA) {
under = underA;
}
| @@ -1849,7 +1849,7 @@ void GfxIndexedColorSpace::getRGBLine(Guchar *in, unsigned int *out, int length)
int i, j, n;
n = base->getNComps();
- line = (Guchar *) gmalloc (length * n);
+ line = (Guchar *) gmallocn (length, n);
for (i = 0; i < length; i++)
for (j = 0; j < n; j++)
line[i * n + j] = l... | CWE-189 | null | null |
765 | GfxRadialShading::GfxRadialShading(double x0A, double y0A, double r0A,
double x1A, double y1A, double r1A,
double t0A, double t1A,
Function **funcsA, int nFuncsA,
GBool extend0A, GBool extend1A):
GfxShading(3)
{
int i;
x0 = x0A;
y0 = y0A;
r0 = r0A;
x1 = x1A;
y1 = y1A;
r1 = r... | DoS Exec Code Overflow | 0 | GfxRadialShading::GfxRadialShading(double x0A, double y0A, double r0A,
double x1A, double y1A, double r1A,
double t0A, double t1A,
Function **funcsA, int nFuncsA,
GBool extend0A, GBool extend1A):
GfxShading(3)
{
int i;
x0 = x0A;
y0 = y0A;
r0 = r0A;
x1 = x1A;
y1 = y1A;
r1 = r... | @@ -1849,7 +1849,7 @@ void GfxIndexedColorSpace::getRGBLine(Guchar *in, unsigned int *out, int length)
int i, j, n;
n = base->getNComps();
- line = (Guchar *) gmalloc (length * n);
+ line = (Guchar *) gmallocn (length, n);
for (i = 0; i < length; i++)
for (j = 0; j < n; j++)
line[i * n + j] = l... | CWE-189 | null | null |
766 | GfxRadialShading::GfxRadialShading(GfxRadialShading *shading):
GfxShading(shading)
{
int i;
x0 = shading->x0;
y0 = shading->y0;
r0 = shading->r0;
x1 = shading->x1;
y1 = shading->y1;
r1 = shading->r1;
t0 = shading->t0;
y1 = shading->t1;
nFuncs = shading->nFuncs;
for (i = 0; i < nFuncs; ++i) {
... | DoS Exec Code Overflow | 0 | GfxRadialShading::GfxRadialShading(GfxRadialShading *shading):
GfxShading(shading)
{
int i;
x0 = shading->x0;
y0 = shading->y0;
r0 = shading->r0;
x1 = shading->x1;
y1 = shading->y1;
r1 = shading->r1;
t0 = shading->t0;
y1 = shading->t1;
nFuncs = shading->nFuncs;
for (i = 0; i < nFuncs; ++i) {
... | @@ -1849,7 +1849,7 @@ void GfxIndexedColorSpace::getRGBLine(Guchar *in, unsigned int *out, int length)
int i, j, n;
n = base->getNComps();
- line = (Guchar *) gmalloc (length * n);
+ line = (Guchar *) gmallocn (length, n);
for (i = 0; i < length; i++)
for (j = 0; j < n; j++)
line[i * n + j] = l... | CWE-189 | null | null |
767 | GfxSeparationColorSpace::GfxSeparationColorSpace(GooString *nameA,
GfxColorSpace *altA,
Function *funcA) {
name = nameA;
alt = altA;
func = funcA;
nonMarking = !name->cmp("None");
}
| DoS Exec Code Overflow | 0 | GfxSeparationColorSpace::GfxSeparationColorSpace(GooString *nameA,
GfxColorSpace *altA,
Function *funcA) {
name = nameA;
alt = altA;
func = funcA;
nonMarking = !name->cmp("None");
}
| @@ -1849,7 +1849,7 @@ void GfxIndexedColorSpace::getRGBLine(Guchar *in, unsigned int *out, int length)
int i, j, n;
n = base->getNComps();
- line = (Guchar *) gmalloc (length * n);
+ line = (Guchar *) gmallocn (length, n);
for (i = 0; i < length; i++)
for (j = 0; j < n; j++)
line[i * n + j] = l... | CWE-189 | null | null |
768 | GfxShading::GfxShading(int typeA) {
type = typeA;
colorSpace = NULL;
}
| DoS Exec Code Overflow | 0 | GfxShading::GfxShading(int typeA) {
type = typeA;
colorSpace = NULL;
}
| @@ -1849,7 +1849,7 @@ void GfxIndexedColorSpace::getRGBLine(Guchar *in, unsigned int *out, int length)
int i, j, n;
n = base->getNComps();
- line = (Guchar *) gmalloc (length * n);
+ line = (Guchar *) gmallocn (length, n);
for (i = 0; i < length; i++)
for (j = 0; j < n; j++)
line[i * n + j] = l... | CWE-189 | null | null |
769 | GfxShading::GfxShading(GfxShading *shading) {
int i;
type = shading->type;
colorSpace = shading->colorSpace->copy();
for (i = 0; i < gfxColorMaxComps; ++i) {
background.c[i] = shading->background.c[i];
}
hasBackground = shading->hasBackground;
xMin = shading->xMin;
yMin = shading->yMin;
xMax = sh... | DoS Exec Code Overflow | 0 | GfxShading::GfxShading(GfxShading *shading) {
int i;
type = shading->type;
colorSpace = shading->colorSpace->copy();
for (i = 0; i < gfxColorMaxComps; ++i) {
background.c[i] = shading->background.c[i];
}
hasBackground = shading->hasBackground;
xMin = shading->xMin;
yMin = shading->yMin;
xMax = sh... | @@ -1849,7 +1849,7 @@ void GfxIndexedColorSpace::getRGBLine(Guchar *in, unsigned int *out, int length)
int i, j, n;
n = base->getNComps();
- line = (Guchar *) gmalloc (length * n);
+ line = (Guchar *) gmallocn (length, n);
for (i = 0; i < length; i++)
for (j = 0; j < n; j++)
line[i * n + j] = l... | CWE-189 | null | null |
770 | GfxShadingBitBuf::GfxShadingBitBuf(Stream *strA) {
str = strA;
str->reset();
bitBuf = 0;
nBits = 0;
}
| DoS Exec Code Overflow | 0 | GfxShadingBitBuf::GfxShadingBitBuf(Stream *strA) {
str = strA;
str->reset();
bitBuf = 0;
nBits = 0;
}
| @@ -1849,7 +1849,7 @@ void GfxIndexedColorSpace::getRGBLine(Guchar *in, unsigned int *out, int length)
int i, j, n;
n = base->getNComps();
- line = (Guchar *) gmalloc (length * n);
+ line = (Guchar *) gmallocn (length, n);
for (i = 0; i < length; i++)
for (j = 0; j < n; j++)
line[i * n + j] = l... | CWE-189 | null | null |
771 | GfxState::GfxState(double hDPIA, double vDPIA, PDFRectangle *pageBox,
int rotateA, GBool upsideDown) {
double kx, ky;
hDPI = hDPIA;
vDPI = vDPIA;
rotate = rotateA;
px1 = pageBox->x1;
py1 = pageBox->y1;
px2 = pageBox->x2;
py2 = pageBox->y2;
kx = hDPI / 72.0;
ky = vDPI / 72.0;
if (rotate == 90... | DoS Exec Code Overflow | 0 | GfxState::GfxState(double hDPIA, double vDPIA, PDFRectangle *pageBox,
int rotateA, GBool upsideDown) {
double kx, ky;
hDPI = hDPIA;
vDPI = vDPIA;
rotate = rotateA;
px1 = pageBox->x1;
py1 = pageBox->y1;
px2 = pageBox->x2;
py2 = pageBox->y2;
kx = hDPI / 72.0;
ky = vDPI / 72.0;
if (rotate == 90... | @@ -1849,7 +1849,7 @@ void GfxIndexedColorSpace::getRGBLine(Guchar *in, unsigned int *out, int length)
int i, j, n;
n = base->getNComps();
- line = (Guchar *) gmalloc (length * n);
+ line = (Guchar *) gmallocn (length, n);
for (i = 0; i < length; i++)
for (j = 0; j < n; j++)
line[i * n + j] = l... | CWE-189 | null | null |
772 | GfxState::GfxState(GfxState *state) {
int i;
memcpy(this, state, sizeof(GfxState));
if (fillColorSpace) {
fillColorSpace = state->fillColorSpace->copy();
}
if (strokeColorSpace) {
strokeColorSpace = state->strokeColorSpace->copy();
}
if (fillPattern) {
fillPattern = state->fillPattern->copy()... | DoS Exec Code Overflow | 0 | GfxState::GfxState(GfxState *state) {
int i;
memcpy(this, state, sizeof(GfxState));
if (fillColorSpace) {
fillColorSpace = state->fillColorSpace->copy();
}
if (strokeColorSpace) {
strokeColorSpace = state->strokeColorSpace->copy();
}
if (fillPattern) {
fillPattern = state->fillPattern->copy()... | @@ -1849,7 +1849,7 @@ void GfxIndexedColorSpace::getRGBLine(Guchar *in, unsigned int *out, int length)
int i, j, n;
n = base->getNComps();
- line = (Guchar *) gmalloc (length * n);
+ line = (Guchar *) gmallocn (length, n);
for (i = 0; i < length; i++)
for (j = 0; j < n; j++)
line[i * n + j] = l... | CWE-189 | null | null |
773 | GfxSubpath::GfxSubpath(double x1, double y1) {
size = 16;
x = (double *)gmallocn(size, sizeof(double));
y = (double *)gmallocn(size, sizeof(double));
curve = (GBool *)gmallocn(size, sizeof(GBool));
n = 1;
x[0] = x1;
y[0] = y1;
curve[0] = gFalse;
closed = gFalse;
}
| DoS Exec Code Overflow | 0 | GfxSubpath::GfxSubpath(double x1, double y1) {
size = 16;
x = (double *)gmallocn(size, sizeof(double));
y = (double *)gmallocn(size, sizeof(double));
curve = (GBool *)gmallocn(size, sizeof(GBool));
n = 1;
x[0] = x1;
y[0] = y1;
curve[0] = gFalse;
closed = gFalse;
}
| @@ -1849,7 +1849,7 @@ void GfxIndexedColorSpace::getRGBLine(Guchar *in, unsigned int *out, int length)
int i, j, n;
n = base->getNComps();
- line = (Guchar *) gmalloc (length * n);
+ line = (Guchar *) gmallocn (length, n);
for (i = 0; i < length; i++)
for (j = 0; j < n; j++)
line[i * n + j] = l... | CWE-189 | null | null |
774 | GfxSubpath::GfxSubpath(GfxSubpath *subpath) {
size = subpath->size;
n = subpath->n;
x = (double *)gmallocn(size, sizeof(double));
y = (double *)gmallocn(size, sizeof(double));
curve = (GBool *)gmallocn(size, sizeof(GBool));
memcpy(x, subpath->x, n * sizeof(double));
memcpy(y, subpath->y, n * sizeof(double... | DoS Exec Code Overflow | 0 | GfxSubpath::GfxSubpath(GfxSubpath *subpath) {
size = subpath->size;
n = subpath->n;
x = (double *)gmallocn(size, sizeof(double));
y = (double *)gmallocn(size, sizeof(double));
curve = (GBool *)gmallocn(size, sizeof(GBool));
memcpy(x, subpath->x, n * sizeof(double));
memcpy(y, subpath->y, n * sizeof(double... | @@ -1849,7 +1849,7 @@ void GfxIndexedColorSpace::getRGBLine(Guchar *in, unsigned int *out, int length)
int i, j, n;
n = base->getNComps();
- line = (Guchar *) gmalloc (length * n);
+ line = (Guchar *) gmallocn (length, n);
for (i = 0; i < length; i++)
for (j = 0; j < n; j++)
line[i * n + j] = l... | CWE-189 | null | null |
775 | GfxTilingPattern::GfxTilingPattern(int paintTypeA, int tilingTypeA,
double *bboxA, double xStepA, double yStepA,
Object *resDictA, double *matrixA,
Object *contentStreamA):
GfxPattern(1)
{
int i;
paintType = paintTypeA;
tilingType = tilingTypeA;
for (i = 0; i < 4; ++i) {
bbox[i] = bb... | DoS Exec Code Overflow | 0 | GfxTilingPattern::GfxTilingPattern(int paintTypeA, int tilingTypeA,
double *bboxA, double xStepA, double yStepA,
Object *resDictA, double *matrixA,
Object *contentStreamA):
GfxPattern(1)
{
int i;
paintType = paintTypeA;
tilingType = tilingTypeA;
for (i = 0; i < 4; ++i) {
bbox[i] = bb... | @@ -1849,7 +1849,7 @@ void GfxIndexedColorSpace::getRGBLine(Guchar *in, unsigned int *out, int length)
int i, j, n;
n = base->getNComps();
- line = (Guchar *) gmalloc (length * n);
+ line = (Guchar *) gmallocn (length, n);
for (i = 0; i < length; i++)
for (j = 0; j < n; j++)
line[i * n + j] = l... | CWE-189 | null | null |
776 | void GfxPath::append(GfxPath *path) {
int i;
if (n + path->n > size) {
size = n + path->n;
subpaths = (GfxSubpath **)
greallocn(subpaths, size, sizeof(GfxSubpath *));
}
for (i = 0; i < path->n; ++i) {
subpaths[n++] = path->subpaths[i]->copy();
}
justMoved = gFalse;
}
| DoS Exec Code Overflow | 0 | void GfxPath::append(GfxPath *path) {
int i;
if (n + path->n > size) {
size = n + path->n;
subpaths = (GfxSubpath **)
greallocn(subpaths, size, sizeof(GfxSubpath *));
}
for (i = 0; i < path->n; ++i) {
subpaths[n++] = path->subpaths[i]->copy();
}
justMoved = gFalse;
}
| @@ -1849,7 +1849,7 @@ void GfxIndexedColorSpace::getRGBLine(Guchar *in, unsigned int *out, int length)
int i, j, n;
n = base->getNComps();
- line = (Guchar *) gmalloc (length * n);
+ line = (Guchar *) gmallocn (length, n);
for (i = 0; i < length; i++)
for (j = 0; j < n; j++)
line[i * n + j] = l... | CWE-189 | null | null |
777 | void GfxState::clearPath() {
delete path;
path = new GfxPath();
}
| DoS Exec Code Overflow | 0 | void GfxState::clearPath() {
delete path;
path = new GfxPath();
}
| @@ -1849,7 +1849,7 @@ void GfxIndexedColorSpace::getRGBLine(Guchar *in, unsigned int *out, int length)
int i, j, n;
n = base->getNComps();
- line = (Guchar *) gmalloc (length * n);
+ line = (Guchar *) gmallocn (length, n);
for (i = 0; i < length; i++)
for (j = 0; j < n; j++)
line[i * n + j] = l... | CWE-189 | null | null |
778 | void GfxState::clip() {
double xMin, yMin, xMax, yMax, x, y;
GfxSubpath *subpath;
int i, j;
xMin = xMax = yMin = yMax = 0; // make gcc happy
for (i = 0; i < path->getNumSubpaths(); ++i) {
subpath = path->getSubpath(i);
for (j = 0; j < subpath->getNumPoints(); ++j) {
transform(subpath->getX(j), ... | DoS Exec Code Overflow | 0 | void GfxState::clip() {
double xMin, yMin, xMax, yMax, x, y;
GfxSubpath *subpath;
int i, j;
xMin = xMax = yMin = yMax = 0; // make gcc happy
for (i = 0; i < path->getNumSubpaths(); ++i) {
subpath = path->getSubpath(i);
for (j = 0; j < subpath->getNumPoints(); ++j) {
transform(subpath->getX(j), ... | @@ -1849,7 +1849,7 @@ void GfxIndexedColorSpace::getRGBLine(Guchar *in, unsigned int *out, int length)
int i, j, n;
n = base->getNComps();
- line = (Guchar *) gmalloc (length * n);
+ line = (Guchar *) gmallocn (length, n);
for (i = 0; i < length; i++)
for (j = 0; j < n; j++)
line[i * n + j] = l... | CWE-189 | null | null |
779 | static inline double clip01(double x) {
return (x < 0) ? 0 : (x > 1) ? 1 : x;
}
| DoS Exec Code Overflow | 0 | static inline double clip01(double x) {
return (x < 0) ? 0 : (x > 1) ? 1 : x;
}
| @@ -1849,7 +1849,7 @@ void GfxIndexedColorSpace::getRGBLine(Guchar *in, unsigned int *out, int length)
int i, j, n;
n = base->getNComps();
- line = (Guchar *) gmalloc (length * n);
+ line = (Guchar *) gmallocn (length, n);
for (i = 0; i < length; i++)
for (j = 0; j < n; j++)
line[i * n + j] = l... | CWE-189 | null | null |
780 | void GfxState::clipToStrokePath() {
double xMin, yMin, xMax, yMax, x, y, t0, t1;
GfxSubpath *subpath;
int i, j;
xMin = xMax = yMin = yMax = 0; // make gcc happy
for (i = 0; i < path->getNumSubpaths(); ++i) {
subpath = path->getSubpath(i);
for (j = 0; j < subpath->getNumPoints(); ++j) {
transfor... | DoS Exec Code Overflow | 0 | void GfxState::clipToStrokePath() {
double xMin, yMin, xMax, yMax, x, y, t0, t1;
GfxSubpath *subpath;
int i, j;
xMin = xMax = yMin = yMax = 0; // make gcc happy
for (i = 0; i < path->getNumSubpaths(); ++i) {
subpath = path->getSubpath(i);
for (j = 0; j < subpath->getNumPoints(); ++j) {
transfor... | @@ -1849,7 +1849,7 @@ void GfxIndexedColorSpace::getRGBLine(Guchar *in, unsigned int *out, int length)
int i, j, n;
n = base->getNComps();
- line = (Guchar *) gmalloc (length * n);
+ line = (Guchar *) gmallocn (length, n);
for (i = 0; i < length; i++)
for (j = 0; j < n; j++)
line[i * n + j] = l... | CWE-189 | null | null |
781 | void GfxSubpath::close() {
if (x[n-1] != x[0] || y[n-1] != y[0]) {
lineTo(x[0], y[0]);
}
closed = gTrue;
}
| DoS Exec Code Overflow | 0 | void GfxSubpath::close() {
if (x[n-1] != x[0] || y[n-1] != y[0]) {
lineTo(x[0], y[0]);
}
closed = gTrue;
}
| @@ -1849,7 +1849,7 @@ void GfxIndexedColorSpace::getRGBLine(Guchar *in, unsigned int *out, int length)
int i, j, n;
n = base->getNComps();
- line = (Guchar *) gmalloc (length * n);
+ line = (Guchar *) gmallocn (length, n);
for (i = 0; i < length; i++)
for (j = 0; j < n; j++)
line[i * n + j] = l... | CWE-189 | null | null |
782 | void GfxPath::close() {
if (justMoved) {
if (n >= size) {
size += 16;
subpaths = (GfxSubpath **)
greallocn(subpaths, size, sizeof(GfxSubpath *));
}
subpaths[n] = new GfxSubpath(firstX, firstY);
++n;
justMoved = gFalse;
}
subpaths[n-1]->close();
}
| DoS Exec Code Overflow | 0 | void GfxPath::close() {
if (justMoved) {
if (n >= size) {
size += 16;
subpaths = (GfxSubpath **)
greallocn(subpaths, size, sizeof(GfxSubpath *));
}
subpaths[n] = new GfxSubpath(firstX, firstY);
++n;
justMoved = gFalse;
}
subpaths[n-1]->close();
}
| @@ -1849,7 +1849,7 @@ void GfxIndexedColorSpace::getRGBLine(Guchar *in, unsigned int *out, int length)
int i, j, n;
n = base->getNComps();
- line = (Guchar *) gmalloc (length * n);
+ line = (Guchar *) gmallocn (length, n);
for (i = 0; i < length; i++)
for (j = 0; j < n; j++)
line[i * n + j] = l... | CWE-189 | null | null |
783 | GfxColorSpace *GfxDeviceGrayColorSpace::copy() {
return new GfxDeviceGrayColorSpace();
}
| DoS Exec Code Overflow | 0 | GfxColorSpace *GfxDeviceGrayColorSpace::copy() {
return new GfxDeviceGrayColorSpace();
}
| @@ -1849,7 +1849,7 @@ void GfxIndexedColorSpace::getRGBLine(Guchar *in, unsigned int *out, int length)
int i, j, n;
n = base->getNComps();
- line = (Guchar *) gmalloc (length * n);
+ line = (Guchar *) gmallocn (length, n);
for (i = 0; i < length; i++)
for (j = 0; j < n; j++)
line[i * n + j] = l... | CWE-189 | null | null |
784 | GfxColorSpace *GfxCalGrayColorSpace::copy() {
GfxCalGrayColorSpace *cs;
cs = new GfxCalGrayColorSpace();
cs->whiteX = whiteX;
cs->whiteY = whiteY;
cs->whiteZ = whiteZ;
cs->blackX = blackX;
cs->blackY = blackY;
cs->blackZ = blackZ;
cs->gamma = gamma;
return cs;
}
| DoS Exec Code Overflow | 0 | GfxColorSpace *GfxCalGrayColorSpace::copy() {
GfxCalGrayColorSpace *cs;
cs = new GfxCalGrayColorSpace();
cs->whiteX = whiteX;
cs->whiteY = whiteY;
cs->whiteZ = whiteZ;
cs->blackX = blackX;
cs->blackY = blackY;
cs->blackZ = blackZ;
cs->gamma = gamma;
return cs;
}
| @@ -1849,7 +1849,7 @@ void GfxIndexedColorSpace::getRGBLine(Guchar *in, unsigned int *out, int length)
int i, j, n;
n = base->getNComps();
- line = (Guchar *) gmalloc (length * n);
+ line = (Guchar *) gmallocn (length, n);
for (i = 0; i < length; i++)
for (j = 0; j < n; j++)
line[i * n + j] = l... | CWE-189 | null | null |
785 | GfxColorSpace *GfxDeviceRGBColorSpace::copy() {
return new GfxDeviceRGBColorSpace();
}
| DoS Exec Code Overflow | 0 | GfxColorSpace *GfxDeviceRGBColorSpace::copy() {
return new GfxDeviceRGBColorSpace();
}
| @@ -1849,7 +1849,7 @@ void GfxIndexedColorSpace::getRGBLine(Guchar *in, unsigned int *out, int length)
int i, j, n;
n = base->getNComps();
- line = (Guchar *) gmalloc (length * n);
+ line = (Guchar *) gmallocn (length, n);
for (i = 0; i < length; i++)
for (j = 0; j < n; j++)
line[i * n + j] = l... | CWE-189 | null | null |
786 | GfxColorSpace *GfxCalRGBColorSpace::copy() {
GfxCalRGBColorSpace *cs;
int i;
cs = new GfxCalRGBColorSpace();
cs->whiteX = whiteX;
cs->whiteY = whiteY;
cs->whiteZ = whiteZ;
cs->blackX = blackX;
cs->blackY = blackY;
cs->blackZ = blackZ;
cs->gammaR = gammaR;
cs->gammaG = gammaG;
cs->gammaB = gamma... | DoS Exec Code Overflow | 0 | GfxColorSpace *GfxCalRGBColorSpace::copy() {
GfxCalRGBColorSpace *cs;
int i;
cs = new GfxCalRGBColorSpace();
cs->whiteX = whiteX;
cs->whiteY = whiteY;
cs->whiteZ = whiteZ;
cs->blackX = blackX;
cs->blackY = blackY;
cs->blackZ = blackZ;
cs->gammaR = gammaR;
cs->gammaG = gammaG;
cs->gammaB = gamma... | @@ -1849,7 +1849,7 @@ void GfxIndexedColorSpace::getRGBLine(Guchar *in, unsigned int *out, int length)
int i, j, n;
n = base->getNComps();
- line = (Guchar *) gmalloc (length * n);
+ line = (Guchar *) gmallocn (length, n);
for (i = 0; i < length; i++)
for (j = 0; j < n; j++)
line[i * n + j] = l... | CWE-189 | null | null |
787 | GfxColorSpace *GfxLabColorSpace::copy() {
GfxLabColorSpace *cs;
cs = new GfxLabColorSpace();
cs->whiteX = whiteX;
cs->whiteY = whiteY;
cs->whiteZ = whiteZ;
cs->blackX = blackX;
cs->blackY = blackY;
cs->blackZ = blackZ;
cs->aMin = aMin;
cs->aMax = aMax;
cs->bMin = bMin;
cs->bMax = bMax;
cs->kr... | DoS Exec Code Overflow | 0 | GfxColorSpace *GfxLabColorSpace::copy() {
GfxLabColorSpace *cs;
cs = new GfxLabColorSpace();
cs->whiteX = whiteX;
cs->whiteY = whiteY;
cs->whiteZ = whiteZ;
cs->blackX = blackX;
cs->blackY = blackY;
cs->blackZ = blackZ;
cs->aMin = aMin;
cs->aMax = aMax;
cs->bMin = bMin;
cs->bMax = bMax;
cs->kr... | @@ -1849,7 +1849,7 @@ void GfxIndexedColorSpace::getRGBLine(Guchar *in, unsigned int *out, int length)
int i, j, n;
n = base->getNComps();
- line = (Guchar *) gmalloc (length * n);
+ line = (Guchar *) gmallocn (length, n);
for (i = 0; i < length; i++)
for (j = 0; j < n; j++)
line[i * n + j] = l... | CWE-189 | null | null |
788 | GfxColorSpace *GfxPatternColorSpace::copy() {
return new GfxPatternColorSpace(under ? under->copy() :
(GfxColorSpace *)NULL);
}
| DoS Exec Code Overflow | 0 | GfxColorSpace *GfxPatternColorSpace::copy() {
return new GfxPatternColorSpace(under ? under->copy() :
(GfxColorSpace *)NULL);
}
| @@ -1849,7 +1849,7 @@ void GfxIndexedColorSpace::getRGBLine(Guchar *in, unsigned int *out, int length)
int i, j, n;
n = base->getNComps();
- line = (Guchar *) gmalloc (length * n);
+ line = (Guchar *) gmallocn (length, n);
for (i = 0; i < length; i++)
for (j = 0; j < n; j++)
line[i * n + j] = l... | CWE-189 | null | null |
789 | GfxPattern *GfxShadingPattern::copy() {
return new GfxShadingPattern(shading->copy(), matrix);
}
| DoS Exec Code Overflow | 0 | GfxPattern *GfxShadingPattern::copy() {
return new GfxShadingPattern(shading->copy(), matrix);
}
| @@ -1849,7 +1849,7 @@ void GfxIndexedColorSpace::getRGBLine(Guchar *in, unsigned int *out, int length)
int i, j, n;
n = base->getNComps();
- line = (Guchar *) gmalloc (length * n);
+ line = (Guchar *) gmallocn (length, n);
for (i = 0; i < length; i++)
for (j = 0; j < n; j++)
line[i * n + j] = l... | CWE-189 | null | null |
790 | GfxShading *GfxFunctionShading::copy() {
return new GfxFunctionShading(this);
}
| DoS Exec Code Overflow | 0 | GfxShading *GfxFunctionShading::copy() {
return new GfxFunctionShading(this);
}
| @@ -1849,7 +1849,7 @@ void GfxIndexedColorSpace::getRGBLine(Guchar *in, unsigned int *out, int length)
int i, j, n;
n = base->getNComps();
- line = (Guchar *) gmalloc (length * n);
+ line = (Guchar *) gmallocn (length, n);
for (i = 0; i < length; i++)
for (j = 0; j < n; j++)
line[i * n + j] = l... | CWE-189 | null | null |
791 | GfxShading *GfxAxialShading::copy() {
return new GfxAxialShading(this);
}
| DoS Exec Code Overflow | 0 | GfxShading *GfxAxialShading::copy() {
return new GfxAxialShading(this);
}
| @@ -1849,7 +1849,7 @@ void GfxIndexedColorSpace::getRGBLine(Guchar *in, unsigned int *out, int length)
int i, j, n;
n = base->getNComps();
- line = (Guchar *) gmalloc (length * n);
+ line = (Guchar *) gmallocn (length, n);
for (i = 0; i < length; i++)
for (j = 0; j < n; j++)
line[i * n + j] = l... | CWE-189 | null | null |
792 | GfxShading *GfxRadialShading::copy() {
return new GfxRadialShading(this);
}
| DoS Exec Code Overflow | 0 | GfxShading *GfxRadialShading::copy() {
return new GfxRadialShading(this);
}
| @@ -1849,7 +1849,7 @@ void GfxIndexedColorSpace::getRGBLine(Guchar *in, unsigned int *out, int length)
int i, j, n;
n = base->getNComps();
- line = (Guchar *) gmalloc (length * n);
+ line = (Guchar *) gmallocn (length, n);
for (i = 0; i < length; i++)
for (j = 0; j < n; j++)
line[i * n + j] = l... | CWE-189 | null | null |
793 | GfxShading *GfxGouraudTriangleShading::copy() {
return new GfxGouraudTriangleShading(this);
}
| DoS Exec Code Overflow | 0 | GfxShading *GfxGouraudTriangleShading::copy() {
return new GfxGouraudTriangleShading(this);
}
| @@ -1849,7 +1849,7 @@ void GfxIndexedColorSpace::getRGBLine(Guchar *in, unsigned int *out, int length)
int i, j, n;
n = base->getNComps();
- line = (Guchar *) gmalloc (length * n);
+ line = (Guchar *) gmallocn (length, n);
for (i = 0; i < length; i++)
for (j = 0; j < n; j++)
line[i * n + j] = l... | CWE-189 | null | null |
794 | GfxShading *GfxPatchMeshShading::copy() {
return new GfxPatchMeshShading(this);
}
| DoS Exec Code Overflow | 0 | GfxShading *GfxPatchMeshShading::copy() {
return new GfxPatchMeshShading(this);
}
| @@ -1849,7 +1849,7 @@ void GfxIndexedColorSpace::getRGBLine(Guchar *in, unsigned int *out, int length)
int i, j, n;
n = base->getNComps();
- line = (Guchar *) gmalloc (length * n);
+ line = (Guchar *) gmallocn (length, n);
for (i = 0; i < length; i++)
for (j = 0; j < n; j++)
line[i * n + j] = l... | CWE-189 | null | null |
795 | void GfxShadingBitBuf::flushBits() {
bitBuf = 0;
nBits = 0;
}
| DoS Exec Code Overflow | 0 | void GfxShadingBitBuf::flushBits() {
bitBuf = 0;
nBits = 0;
}
| @@ -1849,7 +1849,7 @@ void GfxIndexedColorSpace::getRGBLine(Guchar *in, unsigned int *out, int length)
int i, j, n;
n = base->getNComps();
- line = (Guchar *) gmalloc (length * n);
+ line = (Guchar *) gmallocn (length, n);
for (i = 0; i < length; i++)
for (j = 0; j < n; j++)
line[i * n + j] = l... | CWE-189 | null | null |
796 | GBool GfxShadingBitBuf::getBits(int n, Guint *val) {
int x;
if (nBits >= n) {
x = (bitBuf >> (nBits - n)) & ((1 << n) - 1);
nBits -= n;
} else {
x = 0;
if (nBits > 0) {
x = bitBuf & ((1 << nBits) - 1);
n -= nBits;
nBits = 0;
}
while (n > 0) {
if ((bitBuf = str->get... | DoS Exec Code Overflow | 0 | GBool GfxShadingBitBuf::getBits(int n, Guint *val) {
int x;
if (nBits >= n) {
x = (bitBuf >> (nBits - n)) & ((1 << n) - 1);
nBits -= n;
} else {
x = 0;
if (nBits > 0) {
x = bitBuf & ((1 << nBits) - 1);
n -= nBits;
nBits = 0;
}
while (n > 0) {
if ((bitBuf = str->get... | @@ -1849,7 +1849,7 @@ void GfxIndexedColorSpace::getRGBLine(Guchar *in, unsigned int *out, int length)
int i, j, n;
n = base->getNComps();
- line = (Guchar *) gmalloc (length * n);
+ line = (Guchar *) gmallocn (length, n);
for (i = 0; i < length; i++)
for (j = 0; j < n; j++)
line[i * n + j] = l... | CWE-189 | null | null |
797 | unsigned int GfxColorSpace::getCMSColorSpaceType(icColorSpaceSignature cs)
{
switch (cs) {
case icSigXYZData:
return PT_XYZ;
break;
case icSigLabData:
return PT_Lab;
break;
case icSigLuvData:
return PT_YUV;
break;
case icSigYCbCrData:
return PT_YCbCr;
... | DoS Exec Code Overflow | 0 | unsigned int GfxColorSpace::getCMSColorSpaceType(icColorSpaceSignature cs)
{
switch (cs) {
case icSigXYZData:
return PT_XYZ;
break;
case icSigLabData:
return PT_Lab;
break;
case icSigLuvData:
return PT_YUV;
break;
case icSigYCbCrData:
return PT_YCbCr;
... | @@ -1849,7 +1849,7 @@ void GfxIndexedColorSpace::getRGBLine(Guchar *in, unsigned int *out, int length)
int i, j, n;
n = base->getNComps();
- line = (Guchar *) gmalloc (length * n);
+ line = (Guchar *) gmallocn (length, n);
for (i = 0; i < length; i++)
for (j = 0; j < n; j++)
line[i * n + j] = l... | CWE-189 | null | null |
798 | void GfxDeviceGrayColorSpace::getCMYK(GfxColor *color, GfxCMYK *cmyk) {
cmyk->c = cmyk->m = cmyk->y = 0;
cmyk->k = clip01(gfxColorComp1 - color->c[0]);
}
| DoS Exec Code Overflow | 0 | void GfxDeviceGrayColorSpace::getCMYK(GfxColor *color, GfxCMYK *cmyk) {
cmyk->c = cmyk->m = cmyk->y = 0;
cmyk->k = clip01(gfxColorComp1 - color->c[0]);
}
| @@ -1849,7 +1849,7 @@ void GfxIndexedColorSpace::getRGBLine(Guchar *in, unsigned int *out, int length)
int i, j, n;
n = base->getNComps();
- line = (Guchar *) gmalloc (length * n);
+ line = (Guchar *) gmallocn (length, n);
for (i = 0; i < length; i++)
for (j = 0; j < n; j++)
line[i * n + j] = l... | CWE-189 | null | null |
799 | void GfxCalGrayColorSpace::getCMYK(GfxColor *color, GfxCMYK *cmyk) {
GfxRGB rgb;
GfxColorComp c, m, y, k;
#ifdef USE_CMS
if (XYZ2DisplayTransform != NULL && displayPixelType == PT_CMYK) {
double in[gfxColorMaxComps];
Guchar out[gfxColorMaxComps];
double X, Y, Z;
getXYZ(color,&X,&Y,&Z);
i... | DoS Exec Code Overflow | 0 | void GfxCalGrayColorSpace::getCMYK(GfxColor *color, GfxCMYK *cmyk) {
GfxRGB rgb;
GfxColorComp c, m, y, k;
#ifdef USE_CMS
if (XYZ2DisplayTransform != NULL && displayPixelType == PT_CMYK) {
double in[gfxColorMaxComps];
Guchar out[gfxColorMaxComps];
double X, Y, Z;
getXYZ(color,&X,&Y,&Z);
i... | @@ -1849,7 +1849,7 @@ void GfxIndexedColorSpace::getRGBLine(Guchar *in, unsigned int *out, int length)
int i, j, n;
n = base->getNComps();
- line = (Guchar *) gmalloc (length * n);
+ line = (Guchar *) gmallocn (length, n);
for (i = 0; i < length; i++)
for (j = 0; j < n; j++)
line[i * n + j] = l... | CWE-189 | null | null |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.