diff options
author | Didier Raboud <odyx@debian.org> | 2013-06-12 14:23:32 +0200 |
---|---|---|
committer | Didier Raboud <odyx@debian.org> | 2013-06-12 14:23:32 +0200 |
commit | 6b7ae334dc7e1350c89247a3aea31c844128b970 (patch) | |
tree | 07473a9c942897c8ae5c29048e9a29dddca96e07 /ppdc | |
parent | ea5667a811b20e235ce1975e763469edd1f7f0de (diff) | |
download | cups-6b7ae334dc7e1350c89247a3aea31c844128b970.tar.gz |
Imported Upstream version 1.7~b1upstream/1.7_b1
Diffstat (limited to 'ppdc')
-rw-r--r-- | ppdc/Makefile | 6 | ||||
-rw-r--r-- | ppdc/ppdc-driver.cxx | 4 | ||||
-rw-r--r-- | ppdc/ppdc-source.cxx | 18 | ||||
-rw-r--r-- | ppdc/ppdc-string.cxx | 12 | ||||
-rw-r--r-- | ppdc/sample.drv | 8 |
5 files changed, 26 insertions, 22 deletions
diff --git a/ppdc/Makefile b/ppdc/Makefile index 1c1ce2aa..0b636771 100644 --- a/ppdc/Makefile +++ b/ppdc/Makefile @@ -1,5 +1,5 @@ # -# "$Id: Makefile 10191 2012-01-20 19:00:32Z mike $" +# "$Id: Makefile 10768 2012-12-14 13:06:44Z mike $" # # Makefile for the CUPS PPD Compiler. # @@ -145,6 +145,7 @@ install-exec: $(INSTALL_DIR) $(SYMROOT); \ for file in $(EXECTARGETS); do \ cp $$file $(SYMROOT); \ + dsymutil $(SYMROOT)/$$file; \ done \ fi @@ -178,6 +179,7 @@ install-libs: $(INSTALLSTATIC) if test "x$(SYMROOT)" != "x"; then \ $(INSTALL_DIR) $(SYMROOT); \ cp $(LIBCUPSPPDC) $(SYMROOT); \ + dsymutil $(SYMROOT)/$(LIBCUPSPPDC); \ fi installstatic: @@ -400,5 +402,5 @@ include Dependencies # -# End of "$Id: Makefile 10191 2012-01-20 19:00:32Z mike $". +# End of "$Id: Makefile 10768 2012-12-14 13:06:44Z mike $". # diff --git a/ppdc/ppdc-driver.cxx b/ppdc/ppdc-driver.cxx index 6714ab14..2b861932 100644 --- a/ppdc/ppdc-driver.cxx +++ b/ppdc/ppdc-driver.cxx @@ -1,5 +1,5 @@ // -// "$Id: ppdc-driver.cxx 10803 2013-01-11 20:59:59Z mike $" +// "$Id: ppdc-driver.cxx 10631 2012-10-01 03:54:34Z mike $" // // PPD file compiler definitions for the CUPS PPD Compiler. // @@ -1344,5 +1344,5 @@ ppdcDriver::write_ppd_file( // -// End of "$Id: ppdc-driver.cxx 10803 2013-01-11 20:59:59Z mike $". +// End of "$Id: ppdc-driver.cxx 10631 2012-10-01 03:54:34Z mike $". // diff --git a/ppdc/ppdc-source.cxx b/ppdc/ppdc-source.cxx index 91e823c8..7e95a148 100644 --- a/ppdc/ppdc-source.cxx +++ b/ppdc/ppdc-source.cxx @@ -1,9 +1,9 @@ // -// "$Id: ppdc-source.cxx 10378 2012-03-23 21:38:25Z mike $" +// "$Id: ppdc-source.cxx 10845 2013-01-31 13:08:59Z mike $" // // Source class for the CUPS PPD Compiler. // -// Copyright 2007-2012 by Apple Inc. +// Copyright 2007-2013 by Apple Inc. // Copyright 2002-2007 by Easy Software Products. // // These coded instructions, statements, and computer programs are the @@ -943,7 +943,7 @@ ppdcSource::get_filter(ppdcFile *fp) // I - File to read while (isspace(*ptr)) ptr ++; - strcpy(program, ptr); + strlcpy(program, ptr, sizeof(program)); } else { @@ -1706,7 +1706,7 @@ ppdcSource::get_po(ppdcFile *fp) // I - File to read if ((baseptr = strrchr(basedir, '/')) != NULL) *baseptr = '\0'; else - strcpy(basedir, "."); + strlcpy(basedir, ".", sizeof(basedir)); // Find the po file... pofilename[0] = '\0'; @@ -2292,7 +2292,7 @@ ppdcSource::quotef(cups_file_t *fp, // I - File to write to if ((format - bufformat + 1) > (int)sizeof(tformat)) break; - strncpy(tformat, bufformat, format - bufformat); + memcpy(tformat, bufformat, format - bufformat); tformat[format - bufformat] = '\0'; bytes += cupsFilePrintf(fp, tformat, va_arg(ap, double)); @@ -2309,7 +2309,7 @@ ppdcSource::quotef(cups_file_t *fp, // I - File to write to if ((format - bufformat + 1) > (int)sizeof(tformat)) break; - strncpy(tformat, bufformat, format - bufformat); + memcpy(tformat, bufformat, format - bufformat); tformat[format - bufformat] = '\0'; # ifdef HAVE_LONG_LONG @@ -2327,7 +2327,7 @@ ppdcSource::quotef(cups_file_t *fp, // I - File to write to if ((format - bufformat + 1) > (int)sizeof(tformat)) break; - strncpy(tformat, bufformat, format - bufformat); + memcpy(tformat, bufformat, format - bufformat); tformat[format - bufformat] = '\0'; bytes += cupsFilePrintf(fp, tformat, va_arg(ap, void *)); @@ -2630,7 +2630,7 @@ ppdcSource::scan_file(ppdcFile *fp, // I - File to read if ((baseptr = strrchr(basedir, '/')) != NULL) *baseptr = '\0'; else - strcpy(basedir, "."); + strlcpy(basedir, ".", sizeof(basedir)); // Find the include file... if (find_include(inctemp, basedir, incname, sizeof(incname))) @@ -3847,5 +3847,5 @@ ppdcSource::write_file(const char *f) // I - File to write // -// End of "$Id: ppdc-source.cxx 10378 2012-03-23 21:38:25Z mike $". +// End of "$Id: ppdc-source.cxx 10845 2013-01-31 13:08:59Z mike $". // diff --git a/ppdc/ppdc-string.cxx b/ppdc/ppdc-string.cxx index 6f8ef1f9..bd3a53e2 100644 --- a/ppdc/ppdc-string.cxx +++ b/ppdc/ppdc-string.cxx @@ -1,9 +1,9 @@ // -// "$Id: ppdc-string.cxx 8698 2009-06-05 20:49:06Z mike $" +// "$Id: ppdc-string.cxx 10596 2012-09-07 02:49:46Z mike $" // // Shared string class for the CUPS PPD Compiler. // -// Copyright 2007-2009 by Apple Inc. +// Copyright 2007-2012 by Apple Inc. // Copyright 2002-2005 by Easy Software Products. // // These coded instructions, statements, and computer programs are the @@ -36,8 +36,10 @@ ppdcString::ppdcString(const char *v) // I - String if (v) { - value = new char[strlen(v) + 1]; - strcpy(value, v); + size_t vlen = strlen(v); + + value = new char[vlen + 1]; + memcpy(value, v, vlen + 1); } else value = 0; @@ -58,5 +60,5 @@ ppdcString::~ppdcString() // -// End of "$Id: ppdc-string.cxx 8698 2009-06-05 20:49:06Z mike $". +// End of "$Id: ppdc-string.cxx 10596 2012-09-07 02:49:46Z mike $". // diff --git a/ppdc/sample.drv b/ppdc/sample.drv index dc30255a..24a2c09a 100644 --- a/ppdc/sample.drv +++ b/ppdc/sample.drv @@ -1,9 +1,9 @@ // -// "$Id: sample.drv 10431 2012-04-23 19:19:19Z mike $" +// "$Id: sample.drv 10569 2012-08-24 03:13:30Z mike $" // // Driver info file for CUPS-supplied PPDs. // -// Copyright 2007-2011 by Apple Inc. +// Copyright 2007-2012 by Apple Inc. // Copyright 1993-2006 by Easy Software Products. // // These coded instructions, statements, and computer programs are the @@ -103,7 +103,7 @@ #media "w576h468/8.00x6.50\"" 576 468 // Common stuff for all drivers... -Attribute "cupsVersion" "" "1.6" +Attribute "cupsVersion" "" "1.7" Attribute "FileSystem" "" "False" Attribute "LandscapeOrientation" "" "Plus90" Attribute "TTRasterizer" "" "Type42" @@ -1241,5 +1241,5 @@ Version "1.5" } // -// End of "$Id: sample.drv 10431 2012-04-23 19:19:19Z mike $". +// End of "$Id: sample.drv 10569 2012-08-24 03:13:30Z mike $". // |