Blame SOURCES/cups-filters-format-mismatch.patch

e3af14
diff -up cups-filters-1.0.35/filter/pdfutils.c.format-mismatch cups-filters-1.0.35/filter/pdfutils.c
e3af14
--- cups-filters-1.0.35/filter/pdfutils.c.format-mismatch	2013-10-01 12:22:16.244383288 +0100
e3af14
+++ cups-filters-1.0.35/filter/pdfutils.c	2013-10-01 12:24:05.510864420 +0100
e3af14
@@ -242,7 +242,7 @@ void pdfOut_finish_pdf(pdfOut *pdf) // {
e3af14
                     "%010d 65535 f \n",
e3af14
                     0,pdf->xrefsize+1,0);
e3af14
   for (iA=0;iA<pdf->xrefsize;iA++) {
e3af14
-    pdfOut_printf(pdf,"%010d 00000 n \n",
e3af14
+    pdfOut_printf(pdf,"%010ld 00000 n \n",
e3af14
                       pdf->xref[iA]);
e3af14
   }
e3af14
   pdfOut_printf(pdf,"trailer\n"
e3af14
@@ -347,7 +347,7 @@ int pdfOut_write_font(pdfOut *pdf,EMB_PA
e3af14
   const int l0_obj=pdfOut_add_xref(pdf);
e3af14
   assert(l0_obj==ff_obj+1);
e3af14
   pdfOut_printf(pdf,"%d 0 obj\n"
e3af14
-                    "%d\n"
e3af14
+                    "%ld\n"
e3af14
                     "endobj\n"
e3af14
                     ,l0_obj,streamsize);
e3af14
 
e3af14
diff -up cups-filters-1.0.35/filter/pdfutils.h.format-mismatch cups-filters-1.0.35/filter/pdfutils.h
e3af14
--- cups-filters-1.0.35/filter/pdfutils.h.format-mismatch	2012-06-22 17:10:47.000000000 +0100
e3af14
+++ cups-filters-1.0.35/filter/pdfutils.h	2013-10-01 12:07:07.393378641 +0100
e3af14
@@ -42,7 +42,8 @@ void pdfOut_finish_pdf(pdfOut *pdf);
e3af14
 /* General output routine for our pdf.
e3af14
  * Keeps track of characters actually written out
e3af14
  */
e3af14
-void pdfOut_printf(pdfOut *pdf,const char *fmt,...);
e3af14
+void pdfOut_printf(pdfOut *pdf,const char *fmt,...)
e3af14
+  __attribute__((format(printf, 2, 3)));
e3af14
 
e3af14
 /* write out an escaped pdf string: e.g.  (Text \(Test\)\n)
e3af14
  * >len==-1: use strlen(str) 
e3af14
diff -up cups-filters-1.0.35/filter/texttopdf.c.format-mismatch cups-filters-1.0.35/filter/texttopdf.c
e3af14
--- cups-filters-1.0.35/filter/texttopdf.c.format-mismatch	2013-10-01 12:24:41.218021702 +0100
e3af14
+++ cups-filters-1.0.35/filter/texttopdf.c	2013-10-01 12:24:41.863024579 +0100
e3af14
@@ -250,7 +250,7 @@ WritePage(void)
e3af14
   int len_obj=pdfOut_add_xref(pdf);
e3af14
   assert(len_obj==content+1);
e3af14
   pdfOut_printf(pdf,"%d 0 obj\n"
e3af14
-                    "%d\n"
e3af14
+                    "%ld\n"
e3af14
                     "endobj\n",
e3af14
                     len_obj,size);
e3af14
 
e3af14
diff -up cups-filters-1.0.35/fontembed/dynstring.h.format-mismatch cups-filters-1.0.35/fontembed/dynstring.h
e3af14
--- cups-filters-1.0.35/fontembed/dynstring.h.format-mismatch	2012-06-22 17:10:47.000000000 +0100
e3af14
+++ cups-filters-1.0.35/fontembed/dynstring.h	2013-10-01 12:07:07.393378641 +0100
e3af14
@@ -9,7 +9,8 @@ typedef struct {
e3af14
 int dyn_init(DYN_STRING *ds,int reserve_size); // -1 on error
e3af14
 void dyn_free(DYN_STRING *ds);
e3af14
 int dyn_ensure(DYN_STRING *ds,int free_space);
e3af14
-int dyn_printf(DYN_STRING *ds,const char *fmt,...); // appends
e3af14
+int dyn_printf(DYN_STRING *ds,const char *fmt,...) // appends
e3af14
+  __attribute__((format(printf, 2, 3)));
e3af14
 
e3af14
 #endif
e3af14
 
e3af14
diff -up cups-filters-1.0.35/fontembed/embed_sfnt.c.format-mismatch cups-filters-1.0.35/fontembed/embed_sfnt.c
e3af14
--- cups-filters-1.0.35/fontembed/embed_sfnt.c.format-mismatch	2013-10-01 12:25:24.164210823 +0100
e3af14
+++ cups-filters-1.0.35/fontembed/embed_sfnt.c	2013-10-01 12:25:39.727279359 +0100
e3af14
@@ -519,7 +519,7 @@ int emb_otf_ps(OTF_FILE *otf,unsigned sh
e3af14
     free(ds.buf);
e3af14
     return -1;
e3af14
   }
e3af14
-  dyn_printf(&ds,"%!PS-TrueTypeFont-%d-%d\n",
e3af14
+  dyn_printf(&ds,"%%!PS-TrueTypeFont-%d-%d\n",
e3af14
                  otf->version,get_ULONG(head+4));
e3af14
   const int bbxmin=get_SHORT(head+36)*1000/otf->unitsPerEm,
e3af14
             bbymin=get_SHORT(head+38)*1000/otf->unitsPerEm,