Sign Up
Log In
Log In
or
Sign Up
Places
All Projects
Status Monitor
Collapse sidebar
openSUSE:Evergreen:11.2:Test
ghostscript-library
ghostscript-8.64-bnc559122.patch
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
File ghostscript-8.64-bnc559122.patch of Package ghostscript-library
--- base/gsmisc.c +++ base/gsmisc.c 2009-11-24 17:16:39.000000000 +0000 @@ -70,10 +70,10 @@ int outprintf(const gs_memory_t *mem, co va_start(args, fmt); - count = vsprintf(buf, fmt, args); + count = vsnprintf(buf, sizeof (buf), fmt, args); outwrite(mem, buf, count); - if (count >= PRINTF_BUF_LENGTH) { - count = sprintf(buf, + if (count == -1 || count >= sizeof (buf)) { + count = snprintf(buf, sizeof (buf), "PANIC: printf exceeded %d bytes. Stack has been corrupted.\n", PRINTF_BUF_LENGTH); outwrite(mem, buf, count); @@ -90,10 +90,10 @@ int errprintf(const char *fmt, ...) va_start(args, fmt); - count = vsprintf(buf, fmt, args); + count = vsnprintf(buf, sizeof (buf), fmt, args); errwrite(buf, count); - if (count >= PRINTF_BUF_LENGTH) { - count = sprintf(buf, + if (count == -1 || count >= sizeof (buf)) { + count = snprintf(buf, sizeof (buf), "PANIC: printf exceeded %d bytes. Stack has been corrupted.\n", PRINTF_BUF_LENGTH); errwrite(buf, count); @@ -237,7 +237,7 @@ int gs_throw_imp(const char *func, const va_list ap; va_start(ap, fmt); - vsprintf(msg, fmt, ap); + vsnprintf(msg, sizeof (msg), fmt, ap); msg[sizeof(msg) - 1] = 0; va_end(ap); --- base/gxttfb.c +++ base/gxttfb.c 2009-11-24 17:16:39.000000000 +0000 @@ -246,7 +246,7 @@ static int DebugPrint(ttfFont *ttf, cons if (gs_debug_c('Y')) { va_start(args, fmt); - count = vsprintf(buf, fmt, args); + count = vsnprintf(buf, sizeof (buf), fmt, args); /* NB: moved debug output from stdout to stderr */ errwrite(buf, count); --- base/rinkj/rinkj-byte-stream.c +++ base/rinkj/rinkj-byte-stream.c 2009-11-24 17:16:39.000000000 +0000 @@ -43,7 +43,7 @@ rinkj_byte_stream_printf (RinkjByteStrea va_list ap; va_start (ap, fmt); - len = vsprintf (str, fmt, ap); + len = vsnprintf (str, sizeof (str), fmt, ap); va_end (ap); return rinkj_byte_stream_write (bs, str, len); } --- cups/gdevcups.c +++ cups/gdevcups.c 2009-11-24 17:16:12.000000000 +0000 @@ -2727,11 +2727,11 @@ cups_put_params(gx_device *pdev, /* } \ else if (code == 0) \ { \ - dprintf2("DEBUG: Setting %s to \"%s\"...\n", sname, \ - (char *)stringval.data); \ strncpy(cups->header.name, (const char *)stringval.data, \ stringval.size); \ cups->header.name[stringval.size] = '\0'; \ + dprintf2("DEBUG: Setting %s to \"%s\"...\n", sname, \ + cups->header.name); \ } #define intoption(name, sname, type) \
Locations
Projects
Search
Status Monitor
Help
OpenBuildService.org
Documentation
API Documentation
Code of Conduct
Contact
Support
@OBShq
Terms
openSUSE Build Service is sponsored by
The Open Build Service is an
openSUSE project
.
Sign Up
Log In
Places
Places
All Projects
Status Monitor