Blame SOURCES/motif-2.3.4-Fix-issues-with-Werror-format-security.patch

94fd7f
From 4783fb4cec8624311bb87b2eb4a2ac94a5c7d849 Mon Sep 17 00:00:00 2001
94fd7f
From: =?UTF-8?q?Petr=20=C5=A0abata?= <contyk@redhat.com>
94fd7f
Date: Thu, 8 Jun 2017 12:12:04 +0200
94fd7f
Subject: [PATCH] Fix issues with -Werror=format-security
94fd7f
MIME-Version: 1.0
94fd7f
Content-Type: text/plain; charset=UTF-8
94fd7f
Content-Transfer-Encoding: 8bit
94fd7f
94fd7f
Signed-off-by: Petr Ĺ abata <contyk@redhat.com>
94fd7f
---
94fd7f
 lib/Mrm/Mrmhier.c       |   4 +-
94fd7f
 lib/Mrm/Mrmicon.c       |   4 +-
94fd7f
 lib/Mrm/Mrmlread.c      |   2 +-
94fd7f
 lib/Mrm/Mrmwcrw.c       |   4 +-
94fd7f
 tools/wml/wmldbcreate.c |   2 +-
94fd7f
 tools/wml/wmlouth.c     | 128 ++++++++++++++++++++++++------------------------
94fd7f
 tools/wml/wmloutkey.c   |  10 ++--
94fd7f
 tools/wml/wmloutmm.c    |  16 +++---
94fd7f
 tools/wml/wmlresolve.c  |  26 +++++-----
94fd7f
 9 files changed, 98 insertions(+), 98 deletions(-)
94fd7f
94fd7f
diff --git a/lib/Mrm/Mrmhier.c b/lib/Mrm/Mrmhier.c
94fd7f
index 2712742..2a8703c 100644
94fd7f
--- a/lib/Mrm/Mrmhier.c
94fd7f
+++ b/lib/Mrm/Mrmhier.c
94fd7f
@@ -264,10 +264,10 @@ Urm__OpenHierarchy (MrmCount			num_files,
94fd7f
 	    case MrmSUCCESS:
94fd7f
 	      break;
94fd7f
 	    case MrmNOT_VALID:
94fd7f
-	      sprintf (err_stg, _MrmMMsg_0113);
94fd7f
+	      sprintf (err_stg, "%s", _MrmMMsg_0113);
94fd7f
 	      break;
94fd7f
 	    default:
94fd7f
-	      sprintf (err_stg, _MrmMMsg_0114);
94fd7f
+	      sprintf (err_stg, "%s", _MrmMMsg_0114);
94fd7f
 	      break;
94fd7f
 	    }
94fd7f
 	}
94fd7f
diff --git a/lib/Mrm/Mrmicon.c b/lib/Mrm/Mrmicon.c
94fd7f
index 95d4086..191e2d2 100644
94fd7f
--- a/lib/Mrm/Mrmicon.c
94fd7f
+++ b/lib/Mrm/Mrmicon.c
94fd7f
@@ -1176,7 +1176,7 @@ Urm__RealizeColorTable (Screen			*screen,
94fd7f
 		}
94fd7f
 		break;
94fd7f
 	      default:
94fd7f
-		sprintf(err_msg, _MrmMMsg_0040);
94fd7f
+		sprintf(err_msg, "%s", _MrmMMsg_0040);
94fd7f
 		return Urm__UT_Error ("Urm__RelizeColorTable",
94fd7f
 				      err_msg, NULL, NULL, MrmFAILURE) ;
94fd7f
 	      }
94fd7f
@@ -1252,7 +1252,7 @@ Urm__RealizeColorTable (Screen			*screen,
94fd7f
 	      break;
94fd7f
 	    default:
94fd7f
 	      result = MrmFAILURE;
94fd7f
-	      sprintf (err_msg, _MrmMMsg_0040);
94fd7f
+	      sprintf (err_msg, "%s", _MrmMMsg_0040);
94fd7f
 	      Urm__UT_Error ("Urm__RelizeColorTable",
94fd7f
 			     err_msg, NULL, NULL, MrmFAILURE) ;
94fd7f
 	    }
94fd7f
diff --git a/lib/Mrm/Mrmlread.c b/lib/Mrm/Mrmlread.c
94fd7f
index c2fd94c..be433a3 100644
94fd7f
--- a/lib/Mrm/Mrmlread.c
94fd7f
+++ b/lib/Mrm/Mrmlread.c
94fd7f
@@ -698,7 +698,7 @@ MrmFetchColorLiteral (MrmHierarchy                hierarchy_id,
94fd7f
 	 XBlackPixelOfScreen(XDefaultScreenOfDisplay(display)));
94fd7f
       break;
94fd7f
     default:
94fd7f
-      sprintf(err_msg, _MrmMMsg_0040);
94fd7f
+      sprintf(err_msg, "%s", _MrmMMsg_0040);
94fd7f
       result = Urm__UT_Error ("MrmFetchColorLiteral",
94fd7f
 			      err_msg, NULL, NULL, MrmFAILURE) ;
94fd7f
       _MrmAppUnlock(app);
94fd7f
diff --git a/lib/Mrm/Mrmwcrw.c b/lib/Mrm/Mrmwcrw.c
94fd7f
index fe3db52..3c5857f 100644
94fd7f
--- a/lib/Mrm/Mrmwcrw.c
94fd7f
+++ b/lib/Mrm/Mrmwcrw.c
94fd7f
@@ -1390,7 +1390,7 @@ Urm__CW_CreateArglist (Widget			parent,
94fd7f
 			}
94fd7f
 		      break;
94fd7f
 		    default:
94fd7f
-		      sprintf (err_msg, _MrmMMsg_0040);
94fd7f
+		      sprintf (err_msg, "%s", _MrmMMsg_0040);
94fd7f
 		      result = Urm__UT_Error ("Urm__CW_ConvertValue",
94fd7f
 					      err_msg, NULL, NULL, MrmFAILURE) ;
94fd7f
 		    };
94fd7f
@@ -2426,7 +2426,7 @@ Urm__CW_ConvertValue (Widget			parent,
94fd7f
 	    }
94fd7f
 	  break;
94fd7f
 	default:
94fd7f
-	  sprintf(err_msg, _MrmMMsg_0040);
94fd7f
+	  sprintf(err_msg, "%s", _MrmMMsg_0040);
94fd7f
 	  return Urm__UT_Error ("Urm__CW_ConvertValue",
94fd7f
 				err_msg, NULL, NULL, MrmFAILURE) ;
94fd7f
 	};
94fd7f
diff --git a/tools/wml/wmldbcreate.c b/tools/wml/wmldbcreate.c
94fd7f
index 07c0a3c..6de585a 100644
94fd7f
--- a/tools/wml/wmldbcreate.c
94fd7f
+++ b/tools/wml/wmldbcreate.c
94fd7f
@@ -425,7 +425,7 @@ int	table_id;
94fd7f
 		{
94fd7f
 		fprintf (afile, "%d, ", entry_vec[j]);
94fd7f
 		}
94fd7f
-	    fprintf (afile, "\n");
94fd7f
+	    fprintf (afile, "%s", "\n");
94fd7f
 	    }
94fd7f
         }
94fd7f
 }
94fd7f
diff --git a/tools/wml/wmlouth.c b/tools/wml/wmlouth.c
94fd7f
index d2330e3..a52843f 100644
94fd7f
--- a/tools/wml/wmlouth.c
94fd7f
+++ b/tools/wml/wmlouth.c
94fd7f
@@ -225,12 +225,12 @@ if ( outfil == (FILE *) NULL )
94fd7f
     printf ("\nCouldn't open UilSymGen.h");
94fd7f
     return;
94fd7f
     }
94fd7f
-fprintf (outfil, canned_warn);
94fd7f
+fprintf (outfil, "%s", canned_warn);
94fd7f
 
94fd7f
 /*
94fd7f
  * Write the sym_k..._object literals
94fd7f
  */
94fd7f
-fprintf (outfil, canned1);
94fd7f
+fprintf (outfil, "%s", canned1);
94fd7f
 for ( ndx=0 ; ndx<wml_obj_class_ptr->cnt ; ndx++ )
94fd7f
     {
94fd7f
     clsobj = (WmlClassDefPtr) wml_obj_class_ptr->hvec[ndx].objptr;
94fd7f
@@ -244,7 +244,7 @@ for ( ndx=0 ; ndx<wml_obj_class_ptr->cnt ; ndx++ )
94fd7f
 /*
94fd7f
  * Define the sym_k_..._reason literals
94fd7f
  */
94fd7f
-fprintf (outfil, canned3);
94fd7f
+fprintf (outfil, "%s", canned3);
94fd7f
 for ( ndx=0 ; ndx<wml_obj_reason_ptr->cnt ; ndx++ )
94fd7f
     {
94fd7f
     resobj = (WmlResourceDefPtr) wml_obj_reason_ptr->hvec[ndx].objptr;
94fd7f
@@ -258,7 +258,7 @@ for ( ndx=0 ; ndx<wml_obj_reason_ptr->cnt ; ndx++ )
94fd7f
 /*
94fd7f
  * Define the sym_k_..._arg literals
94fd7f
  */
94fd7f
-fprintf (outfil, canned4);
94fd7f
+fprintf (outfil, "%s", canned4);
94fd7f
 for ( ndx=0 ; ndx<wml_obj_arg_ptr->cnt ; ndx++ )
94fd7f
     {
94fd7f
     resobj = (WmlResourceDefPtr) wml_obj_arg_ptr->hvec[ndx].objptr;
94fd7f
@@ -272,7 +272,7 @@ for ( ndx=0 ; ndx<wml_obj_arg_ptr->cnt ; ndx++ )
94fd7f
 /*
94fd7f
  * Define the sym_k_..._enumset structs and literals
94fd7f
  */
94fd7f
-fprintf (outfil, canned5);
94fd7f
+fprintf (outfil, "%s", canned5);
94fd7f
 for ( ndx=0 ; ndx<wml_obj_enumset_ptr->cnt ; ndx++ )
94fd7f
     {
94fd7f
     enumsetobj = (WmlEnumSetDefPtr) wml_obj_enumset_ptr->hvec[ndx].objptr;
94fd7f
@@ -286,7 +286,7 @@ for ( ndx=0 ; ndx<wml_obj_enumset_ptr->cnt ; ndx++ )
94fd7f
 /*
94fd7f
  * Define the sym_k_..._enumval literals
94fd7f
  */
94fd7f
-fprintf (outfil, canned6);
94fd7f
+fprintf (outfil, "%s", canned6);
94fd7f
 for ( ndx=0 ; ndx<wml_obj_enumval_ptr->cnt ; ndx++ )
94fd7f
     {
94fd7f
     enumvalobj = (WmlEnumValueDefPtr) wml_obj_enumval_ptr->hvec[ndx].objptr;
94fd7f
@@ -301,7 +301,7 @@ for ( ndx=0 ; ndx<wml_obj_enumval_ptr->cnt ; ndx++ )
94fd7f
  * Define the sym_k_..._charsize literals
94fd7f
  * Define the sym_k_..._charset literals
94fd7f
  */
94fd7f
-fprintf (outfil, canned7);
94fd7f
+fprintf (outfil, "%s", canned7);
94fd7f
 for ( ndx=0 ; ndx<wml_obj_charset_ptr->cnt ; ndx++ )
94fd7f
     {
94fd7f
     charsetobj = (WmlCharSetDefPtr) wml_obj_charset_ptr->hvec[ndx].objptr;
94fd7f
@@ -315,7 +315,7 @@ for ( ndx=0 ; ndx<wml_obj_charset_ptr->cnt ; ndx++ )
94fd7f
 /*
94fd7f
  * Define the sym_k_..._child literals
94fd7f
  */
94fd7f
-fprintf (outfil, canned8);
94fd7f
+fprintf (outfil, "%s", canned8);
94fd7f
 for ( ndx=0 ; ndx<wml_obj_child_ptr->cnt ; ndx++ )
94fd7f
     {
94fd7f
     childobj = (WmlChildDefPtr) wml_obj_child_ptr->hvec[ndx].objptr;
94fd7f
@@ -379,12 +379,12 @@ if ( outfil == (FILE *) NULL )
94fd7f
     printf ("\nCouldn't open UilSymChCL.h");
94fd7f
     return;
94fd7f
     }
94fd7f
-fprintf (outfil, canned_warn);
94fd7f
+fprintf (outfil, "%s", canned_warn);
94fd7f
 
94fd7f
 /*
94fd7f
  * Create table entries, similar to writing sym_k...
94fd7f
  */
94fd7f
-fprintf (outfil, canned1);
94fd7f
+fprintf (outfil, "%s", canned1);
94fd7f
 for ( ndx=0 ; ndx<wml_obj_child_ptr->cnt ; ndx++ )
94fd7f
     {
94fd7f
     childobj = (WmlChildDefPtr) wml_obj_child_ptr->hvec[ndx].objptr;
94fd7f
@@ -392,7 +392,7 @@ for ( ndx=0 ; ndx<wml_obj_child_ptr->cnt ; ndx++ )
94fd7f
     fprintf (outfil, "    sym_k_%s_object,\n",
94fd7f
 	     classobj->tkname);
94fd7f
     }
94fd7f
-fprintf (outfil, canned1a);
94fd7f
+fprintf (outfil, "%s", canned1a);
94fd7f
 
94fd7f
 /*
94fd7f
  * close the output file
94fd7f
@@ -446,12 +446,12 @@ if ( outfil == (FILE *) NULL )
94fd7f
     printf ("\nCouldn't open UilSymArTy.h");
94fd7f
     return;
94fd7f
     }
94fd7f
-fprintf (outfil, canned_warn);
94fd7f
+fprintf (outfil, "%s", canned_warn);
94fd7f
 
94fd7f
 /*
94fd7f
  * Create table entries, similar to writing sym_k...
94fd7f
  */
94fd7f
-fprintf (outfil, canned1);
94fd7f
+fprintf (outfil, "%s", canned1);
94fd7f
 for ( ndx=0 ; ndx<wml_obj_arg_ptr->cnt ; ndx++ )
94fd7f
     {
94fd7f
     resobj = (WmlResourceDefPtr) wml_obj_arg_ptr->hvec[ndx].objptr;
94fd7f
@@ -459,7 +459,7 @@ for ( ndx=0 ; ndx<wml_obj_arg_ptr->cnt ; ndx++ )
94fd7f
     fprintf (outfil, "    sym_k_%s_value,\n",
94fd7f
 	     datobj->tkname);
94fd7f
     }
94fd7f
-fprintf (outfil, canned1a);
94fd7f
+fprintf (outfil, "%s", canned1a);
94fd7f
 
94fd7f
 /*
94fd7f
  * close the output file
94fd7f
@@ -509,19 +509,19 @@ if ( outfil == (FILE *) NULL )
94fd7f
     printf ("\nCouldn't open UilSymRArg.h");
94fd7f
     return;
94fd7f
     }
94fd7f
-fprintf (outfil, canned_warn);
94fd7f
+fprintf (outfil, "%s", canned_warn);
94fd7f
 
94fd7f
 /*
94fd7f
  * Create table entries, similar to writing sym_k...
94fd7f
  */
94fd7f
-fprintf (outfil, canned1);
94fd7f
+fprintf (outfil, "%s", canned1);
94fd7f
 for ( ndx=0 ; ndx<wml_obj_arg_ptr->cnt ; ndx++ )
94fd7f
     {
94fd7f
     resobj = (WmlResourceDefPtr) wml_obj_arg_ptr->hvec[ndx].objptr;
94fd7f
     fprintf (outfil, "    %d,\n",
94fd7f
 	     resobj->related_code);
94fd7f
     }
94fd7f
-fprintf (outfil, canned1a);
94fd7f
+fprintf (outfil, "%s", canned1a);
94fd7f
 
94fd7f
 /*
94fd7f
  * close the output file
94fd7f
@@ -621,12 +621,12 @@ if ( outfil == (FILE *) NULL )
94fd7f
     printf ("\nCouldn't open UilUrmClas.h");
94fd7f
     return;
94fd7f
     }
94fd7f
-fprintf (outfil, canned_warn);
94fd7f
+fprintf (outfil, "%s", canned_warn);
94fd7f
 
94fd7f
 /*
94fd7f
  * Write entries for widgets
94fd7f
  */
94fd7f
-fprintf (outfil, canned1);
94fd7f
+fprintf (outfil, "%s", canned1);
94fd7f
 for ( ndx=0 ; ndx<wml_obj_class_ptr->cnt ; ndx++ )
94fd7f
     {
94fd7f
     clsobj = (WmlClassDefPtr) wml_obj_class_ptr->hvec[ndx].objptr;
94fd7f
@@ -637,7 +637,7 @@ for ( ndx=0 ; ndx<wml_obj_class_ptr->cnt ; ndx++ )
94fd7f
     else 
94fd7f
 	fprintf (outfil, "  \"%s\",\t\n", synobj->convfunc);
94fd7f
     }
94fd7f
-fprintf (outfil, canned2);
94fd7f
+fprintf (outfil, "%s", canned2);
94fd7f
 
94fd7f
 /*
94fd7f
  * Write entries for gadget variants of widget classes
94fd7f
@@ -661,7 +661,7 @@ for ( ndx=0 ; ndx<wml_obj_class_ptr->cnt ; ndx++ )
94fd7f
 		     synobj->name);
94fd7f
 	}
94fd7f
     }
94fd7f
-fprintf (outfil, canned3);
94fd7f
+fprintf (outfil, "%s", canned3);
94fd7f
 
94fd7f
 /*
94fd7f
  * Write entries for non-dialog widgets
94fd7f
@@ -685,7 +685,7 @@ for ( ndx=0 ; ndx<wml_obj_class_ptr->cnt ; ndx++ )
94fd7f
 		     synobj->name);
94fd7f
 	}
94fd7f
     }
94fd7f
-fprintf (outfil, canned4);
94fd7f
+fprintf (outfil, "%s", canned4);
94fd7f
 
94fd7f
 /*
94fd7f
  * Write entries for the resource a widget's controls map to
94fd7f
@@ -701,7 +701,7 @@ for ( ndx=0 ; ndx<wml_obj_class_ptr->cnt ; ndx++ )
94fd7f
     else
94fd7f
 	fprintf (outfil, "  sym_k_%s_arg,\n", mapresobj->tkname);
94fd7f
     }
94fd7f
-fprintf (outfil, canned5);
94fd7f
+fprintf (outfil, "%s", canned5);
94fd7f
 
94fd7f
 /*
94fd7f
  * Write entries for arguments
94fd7f
@@ -714,7 +714,7 @@ for ( ndx=0 ; ndx<wml_obj_arg_ptr->cnt ; ndx++ )
94fd7f
     fprintf (outfil, "  %s,\n",
94fd7f
 	     synres->resliteral);
94fd7f
     }
94fd7f
-fprintf (outfil, canned6);
94fd7f
+fprintf (outfil, "%s", canned6);
94fd7f
 
94fd7f
 /*
94fd7f
  * Write entries for reasons
94fd7f
@@ -727,7 +727,7 @@ for ( ndx=0 ; ndx<wml_obj_reason_ptr->cnt ; ndx++ )
94fd7f
     fprintf (outfil, "  %s,\n",
94fd7f
 	     synres->resliteral);
94fd7f
     }
94fd7f
-fprintf (outfil, canned7);
94fd7f
+fprintf (outfil, "%s", canned7);
94fd7f
 
94fd7f
 /*
94fd7f
  * close the output file
94fd7f
@@ -781,13 +781,13 @@ if ( outfil == (FILE *) NULL )
94fd7f
     printf ("\nCouldn't open UilConst.h");
94fd7f
     return;
94fd7f
     }
94fd7f
-fprintf (outfil, canned_warn);
94fd7f
+fprintf (outfil, "%s", canned_warn);
94fd7f
 
94fd7f
 /*
94fd7f
  * Process the arguments in code order. We start with 1, and write out
94fd7f
  * the mask after processing 8 codes.
94fd7f
  */
94fd7f
-fprintf (outfil, canned1);
94fd7f
+fprintf (outfil, "%s", canned1);
94fd7f
 strcpy (maskbuf, "0");
94fd7f
 for ( ndx=0 ; ndx<wml_obj_arg_ptr->cnt ; ndx++ )
94fd7f
     {
94fd7f
@@ -805,7 +805,7 @@ for ( ndx=0 ; ndx<wml_obj_arg_ptr->cnt ; ndx++ )
94fd7f
     }
94fd7f
 if ( bitno != 8 )
94fd7f
     fprintf (outfil, "%s", maskbuf);
94fd7f
-fprintf (outfil, canned1a);
94fd7f
+fprintf (outfil, "%s", canned1a);
94fd7f
 
94fd7f
 /*
94fd7f
  * close the output file
94fd7f
@@ -878,8 +878,8 @@ if ( outfil == (FILE *) NULL )
94fd7f
     printf ("\nCouldn't open UilSymReas.h");
94fd7f
     return;
94fd7f
     }
94fd7f
-fprintf (outfil, canned_warn);
94fd7f
-fprintf (outfil, canned1);
94fd7f
+fprintf (outfil, "%s", canned_warn);
94fd7f
+fprintf (outfil, "%s", canned1);
94fd7f
 
94fd7f
 /*
94fd7f
  * Generate the bit vectors for each class. Outer loop on the reason code,
94fd7f
@@ -919,19 +919,19 @@ for ( resndx=0 ; resndx<wml_obj_reason_ptr->cnt ; resndx++ )
94fd7f
     if ( itemno != 0 )
94fd7f
 	fprintf (outfil, "%s 0};\n", maskbuf);
94fd7f
     else
94fd7f
-	fprintf (outfil, "};\n");
94fd7f
+	fprintf (outfil, "%s", "};\n");
94fd7f
     }
94fd7f
 
94fd7f
 /*
94fd7f
  * Write the vector of vectors.
94fd7f
  */
94fd7f
-fprintf (outfil, canned2);
94fd7f
+fprintf (outfil, "%s", canned2);
94fd7f
 for ( resndx=0 ; resndx<wml_obj_reason_ptr->cnt ; resndx++ )
94fd7f
     {
94fd7f
     resobj = (WmlResourceDefPtr) wml_obj_reason_ptr->hvec[resndx].objptr;
94fd7f
     fprintf (outfil, "  reason_class_vec%d,\n", resobj->sym_code);
94fd7f
     }
94fd7f
-fprintf (outfil, canned3);
94fd7f
+fprintf (outfil, "%s", canned3);
94fd7f
 
94fd7f
 /*
94fd7f
  * close the output file
94fd7f
@@ -1004,8 +1004,8 @@ if ( outfil == (FILE *) NULL )
94fd7f
     printf ("\nCouldn't open UilSymArTa.h");
94fd7f
     return;
94fd7f
     }
94fd7f
-fprintf (outfil, canned_warn);
94fd7f
-fprintf (outfil, canned1);
94fd7f
+fprintf (outfil, "%s", canned_warn);
94fd7f
+fprintf (outfil, "%s", canned1);
94fd7f
 
94fd7f
 /*
94fd7f
  * Generate the bit vectors for each class. Outer loop on the argument code,
94fd7f
@@ -1045,19 +1045,19 @@ for ( resndx=0 ; resndx<wml_obj_arg_ptr->cnt ; resndx++ )
94fd7f
     if ( itemno != 0 )
94fd7f
 	fprintf (outfil, "%s 0};\n", maskbuf);
94fd7f
     else
94fd7f
-	fprintf (outfil, "};\n");
94fd7f
+	fprintf (outfil, "%s", "};\n");
94fd7f
     }
94fd7f
 
94fd7f
 /*
94fd7f
  * Write the vector of vectors.
94fd7f
  */
94fd7f
-fprintf (outfil, canned2);
94fd7f
+fprintf (outfil, "%s", canned2);
94fd7f
 for ( resndx=0 ; resndx<wml_obj_arg_ptr->cnt ; resndx++ )
94fd7f
     {
94fd7f
     resobj = (WmlResourceDefPtr) wml_obj_arg_ptr->hvec[resndx].objptr;
94fd7f
     fprintf (outfil, "  arg_class_vec%d,\n", resobj->sym_code);
94fd7f
     }
94fd7f
-fprintf (outfil, canned3);
94fd7f
+fprintf (outfil, "%s", canned3);
94fd7f
 
94fd7f
 /*
94fd7f
  * close the output file
94fd7f
@@ -1129,8 +1129,8 @@ if ( outfil == (FILE *) NULL )
94fd7f
     printf ("\nCouldn't open UilSymChTa.h");
94fd7f
     return;
94fd7f
     }
94fd7f
-fprintf (outfil, canned_warn);
94fd7f
-fprintf (outfil, canned1);
94fd7f
+fprintf (outfil, "%s", canned_warn);
94fd7f
+fprintf (outfil, "%s", canned1);
94fd7f
 
94fd7f
 /*
94fd7f
  * Generate the bit vectors for each class. Outer loop on the child code,
94fd7f
@@ -1168,19 +1168,19 @@ for ( childndx=0 ; childndx<wml_obj_child_ptr->cnt ; childndx++ )
94fd7f
     if ( itemno != 0 )
94fd7f
 	fprintf (outfil, "%s 0};\n", maskbuf);
94fd7f
     else
94fd7f
-	fprintf (outfil, "};\n");
94fd7f
+	fprintf (outfil, "%s", "};\n");
94fd7f
     }
94fd7f
 
94fd7f
 /*
94fd7f
  * Write the vector of vectors.
94fd7f
  */
94fd7f
-fprintf (outfil, canned2);
94fd7f
+fprintf (outfil, "%s", canned2);
94fd7f
 for ( childndx=0 ; childndx<wml_obj_child_ptr->cnt ; childndx++ )
94fd7f
     {
94fd7f
     childobj = (WmlChildDefPtr) wml_obj_child_ptr->hvec[childndx].objptr;
94fd7f
     fprintf (outfil, "  child_class_vec%d,\n", childobj->sym_code);
94fd7f
     }
94fd7f
-fprintf (outfil, canned3);
94fd7f
+fprintf (outfil, "%s", canned3);
94fd7f
 
94fd7f
 /*
94fd7f
  * close the output file
94fd7f
@@ -1251,8 +1251,8 @@ if ( outfil == (FILE *) NULL )
94fd7f
     printf ("\nCouldn't open UilSymCtl.h");
94fd7f
     return;
94fd7f
     }
94fd7f
-fprintf (outfil, canned_warn);
94fd7f
-fprintf (outfil, canned1);
94fd7f
+fprintf (outfil, "%s", canned_warn);
94fd7f
+fprintf (outfil, "%s", canned1);
94fd7f
 
94fd7f
 /*
94fd7f
  * Generate the bit vectors for each class. Outer loop on the class code,
94fd7f
@@ -1290,19 +1290,19 @@ for ( ctlndx=0 ; ctlndx<wml_obj_class_ptr->cnt ; ctlndx++ )
94fd7f
     if ( itemno != 0 )
94fd7f
 	fprintf (outfil, "%s 0};\n", maskbuf);
94fd7f
     else
94fd7f
-	fprintf (outfil, "};\n");
94fd7f
+	fprintf (outfil, "%s", "};\n");
94fd7f
     }
94fd7f
 
94fd7f
 /*
94fd7f
  * Write the vector of vectors.
94fd7f
  */
94fd7f
-fprintf (outfil, canned2);
94fd7f
+fprintf (outfil, "%s", canned2);
94fd7f
 for ( ctlndx=0 ; ctlndx<wml_obj_class_ptr->cnt ; ctlndx++ )
94fd7f
     {
94fd7f
     clsobj = (WmlClassDefPtr) wml_obj_class_ptr->hvec[ctlndx].objptr;
94fd7f
     fprintf (outfil, "  object_class_vec%d,\n", clsobj->sym_code);
94fd7f
     }
94fd7f
-fprintf (outfil, canned3);
94fd7f
+fprintf (outfil, "%s", canned3);
94fd7f
 
94fd7f
 /*
94fd7f
  * close the output file
94fd7f
@@ -1438,7 +1438,7 @@ if ( outfil == (FILE *) NULL )
94fd7f
     printf ("\nCouldn't open UilSymNam.h");
94fd7f
     return;
94fd7f
     }
94fd7f
-fprintf (outfil, canned_warn);
94fd7f
+fprintf (outfil, "%s", canned_warn);
94fd7f
 
94fd7f
 /*
94fd7f
  * Write entries for widgets
94fd7f
@@ -1517,7 +1517,7 @@ for ( ndx=0 ; ndx<wml_obj_child_ptr->cnt ; ndx++ )
94fd7f
     fprintf (outfil, "    \"%s\",\n",
94fd7f
 	     synch->name);
94fd7f
     }
94fd7f
-fprintf (outfil, canned7);
94fd7f
+fprintf (outfil, "%s", canned7);
94fd7f
 
94fd7f
 /*
94fd7f
  * close the output file
94fd7f
@@ -1621,12 +1621,12 @@ if ( outfil == (FILE *) NULL )
94fd7f
     printf ("\nCouldn't open UilSymEnum.h");
94fd7f
     return;
94fd7f
     }
94fd7f
-fprintf (outfil, canned_warn);
94fd7f
+fprintf (outfil, "%s", canned_warn);
94fd7f
 
94fd7f
 /*
94fd7f
  * Generate the enumeration value vectors for each enumeration set.
94fd7f
  */
94fd7f
-fprintf (outfil, canned1);
94fd7f
+fprintf (outfil, "%s", canned1);
94fd7f
 for ( ndx=0 ; ndx<wml_obj_enumset_ptr->cnt ; ndx++ )
94fd7f
     {
94fd7f
     enumsetobj = (WmlEnumSetDefPtr) wml_obj_enumset_ptr->hvec[ndx].objptr;
94fd7f
@@ -1637,13 +1637,13 @@ for ( ndx=0 ; ndx<wml_obj_enumset_ptr->cnt ; ndx++ )
94fd7f
 	fprintf (outfil, "    %d,\n",
94fd7f
 		 evobj->sym_code);
94fd7f
 	}
94fd7f
-    fprintf (outfil, "  };\n");
94fd7f
+    fprintf (outfil, "%s", "  };\n");
94fd7f
     }
94fd7f
 
94fd7f
 /*
94fd7f
  * Generate the enumeration set tables
94fd7f
  */
94fd7f
-fprintf (outfil, canned3);
94fd7f
+fprintf (outfil, "%s", canned3);
94fd7f
 for ( ndx=0 ; ndx<wml_obj_enumset_ptr->cnt ; ndx++ )
94fd7f
     {
94fd7f
     enumsetobj = (WmlEnumSetDefPtr) wml_obj_enumset_ptr->hvec[ndx].objptr;
94fd7f
@@ -1655,7 +1655,7 @@ for ( ndx=0 ; ndx<wml_obj_enumset_ptr->cnt ; ndx++ )
94fd7f
 /*
94fd7f
  * Create enumset table entries for arguments, similar to writing sym_k...
94fd7f
  */
94fd7f
-fprintf (outfil, canned4);
94fd7f
+fprintf (outfil, "%s", canned4);
94fd7f
 for ( ndx=0 ; ndx<wml_obj_arg_ptr->cnt ; ndx++ )
94fd7f
     {
94fd7f
     resobj = (WmlResourceDefPtr) wml_obj_arg_ptr->hvec[ndx].objptr;
94fd7f
@@ -1669,13 +1669,13 @@ for ( ndx=0 ; ndx<wml_obj_arg_ptr->cnt ; ndx++ )
94fd7f
 /*
94fd7f
  * Create the enumval values table.
94fd7f
  */
94fd7f
-fprintf (outfil, canned5);
94fd7f
+fprintf (outfil, "%s", canned5);
94fd7f
 for ( ndx=0 ; ndx<wml_obj_enumval_ptr->cnt ; ndx++ )
94fd7f
     {
94fd7f
     evobj = (WmlEnumValueDefPtr) wml_obj_enumval_ptr->hvec[ndx].objptr;
94fd7f
     fprintf (outfil, "  %s,\n", evobj->syndef->enumlit);
94fd7f
     }
94fd7f
-fprintf (outfil, canned5a);
94fd7f
+fprintf (outfil, "%s", canned5a);
94fd7f
 
94fd7f
 /*
94fd7f
  * close the output file
94fd7f
@@ -1813,12 +1813,12 @@ if ( outfil == (FILE *) NULL )
94fd7f
     printf ("\nCouldn't open UilSymCSet.h");
94fd7f
     return;
94fd7f
     }
94fd7f
-fprintf (outfil, canned_warn);
94fd7f
+fprintf (outfil, "%s", canned_warn);
94fd7f
 
94fd7f
 /*
94fd7f
  * Generate the standards name table
94fd7f
  */
94fd7f
-fprintf (outfil, canned1);
94fd7f
+fprintf (outfil, "%s", canned1);
94fd7f
 for ( ndx=0 ; ndx<wml_obj_charset_ptr->cnt ; ndx++ )
94fd7f
     {
94fd7f
     csobj = (WmlCharSetDefPtr) wml_obj_charset_ptr->hvec[ndx].objptr;
94fd7f
@@ -1836,7 +1836,7 @@ for ( ndx=0 ; ndx<wml_obj_charset_ptr->cnt ; ndx++ )
94fd7f
 /*
94fd7f
  * Generate the writing direction table
94fd7f
  */
94fd7f
-fprintf (outfil, canned2);
94fd7f
+fprintf (outfil, "%s", canned2);
94fd7f
 for ( ndx=0 ; ndx<wml_obj_charset_ptr->cnt ; ndx++ )
94fd7f
     {
94fd7f
     csobj = (WmlCharSetDefPtr) wml_obj_charset_ptr->hvec[ndx].objptr;
94fd7f
@@ -1858,7 +1858,7 @@ for ( ndx=0 ; ndx<wml_obj_charset_ptr->cnt ; ndx++ )
94fd7f
 /*
94fd7f
  * Generate the parsing direction table
94fd7f
  */
94fd7f
-fprintf (outfil, canned3);
94fd7f
+fprintf (outfil, "%s", canned3);
94fd7f
 for ( ndx=0 ; ndx<wml_obj_charset_ptr->cnt ; ndx++ )
94fd7f
     {
94fd7f
     csobj = (WmlCharSetDefPtr) wml_obj_charset_ptr->hvec[ndx].objptr;
94fd7f
@@ -1880,7 +1880,7 @@ for ( ndx=0 ; ndx<wml_obj_charset_ptr->cnt ; ndx++ )
94fd7f
 /*
94fd7f
  * Generate the character size table
94fd7f
  */
94fd7f
-fprintf (outfil, canned4);
94fd7f
+fprintf (outfil, "%s", canned4);
94fd7f
 for ( ndx=0 ; ndx<wml_obj_charset_ptr->cnt ; ndx++ )
94fd7f
     {
94fd7f
     csobj = (WmlCharSetDefPtr) wml_obj_charset_ptr->hvec[ndx].objptr;
94fd7f
@@ -1906,7 +1906,7 @@ for ( ndx=0 ; ndx<wml_obj_charset_ptr->cnt ; ndx++ )
94fd7f
 /*
94fd7f
  * Generate the $LANG name recognition table
94fd7f
  */
94fd7f
-fprintf (outfil, canned5);
94fd7f
+fprintf (outfil, "%s", canned5);
94fd7f
 lang_max = 0;
94fd7f
 for ( ndx=0 ; ndx<wml_obj_charset_ptr->cnt ; ndx++ )
94fd7f
     {
94fd7f
@@ -1936,7 +1936,7 @@ for ( ndx=0 ; ndx<wml_obj_charset_ptr->cnt ; ndx++ )
94fd7f
 /*
94fd7f
  * Generate the $LANG code lookup table, in upper case
94fd7f
  */
94fd7f
-fprintf (outfil, canned6);
94fd7f
+fprintf (outfil, "%s", canned6);
94fd7f
 for ( ndx=0 ; ndx<wml_obj_charset_ptr->cnt ; ndx++ )
94fd7f
     {
94fd7f
     csobj = (WmlCharSetDefPtr) wml_obj_charset_ptr->hvec[ndx].objptr;
94fd7f
diff --git a/tools/wml/wmloutkey.c b/tools/wml/wmloutkey.c
94fd7f
index af42f22..4c14728 100644
94fd7f
--- a/tools/wml/wmloutkey.c
94fd7f
+++ b/tools/wml/wmloutkey.c
94fd7f
@@ -574,16 +574,16 @@ if ( outfil == NULL )
94fd7f
     printf ("\nCouldn't open UilKeyTab.h");
94fd7f
     return;
94fd7f
     }
94fd7f
-fprintf (outfil, canned_warn);
94fd7f
+fprintf (outfil, "%s", canned_warn);
94fd7f
 
94fd7f
 /*
94fd7f
  * Print the case sensitive and insensitive tables
94fd7f
  */
94fd7f
-fprintf (outfil, canned1);
94fd7f
+fprintf (outfil, "%s", canned1);
94fd7f
 wmlOutputUilKeyTabBody (outfil, wml_tok_sens_ptr, &maxlen, &maxkey);
94fd7f
 fprintf (outfil, canned2, maxlen, maxkey);
94fd7f
 wmlOutputUilKeyTabBody (outfil, wml_tok_insens_ptr, &maxlen, &maxkey);
94fd7f
-fprintf (outfil, canned3);
94fd7f
+fprintf (outfil, "%s", canned3);
94fd7f
 
94fd7f
 /*
94fd7f
  * close the output file
94fd7f
@@ -812,8 +812,8 @@ if ( outfil == NULL )
94fd7f
     printf ("\nCouldn't open UilTokName.h");
94fd7f
     return;
94fd7f
     }
94fd7f
-fprintf (outfil, canned_warn);
94fd7f
-fprintf (outfil, canned1);
94fd7f
+fprintf (outfil, "%s", canned_warn);
94fd7f
+fprintf (outfil, "%s", canned1);
94fd7f
 
94fd7f
 /*
94fd7f
  * Print the token name entries
94fd7f
diff --git a/tools/wml/wmloutmm.c b/tools/wml/wmloutmm.c
94fd7f
index 84a97bb..dc8ec09 100644
94fd7f
--- a/tools/wml/wmloutmm.c
94fd7f
+++ b/tools/wml/wmloutmm.c
94fd7f
@@ -209,9 +209,9 @@ int			ctlndx;		/* to access ordered vector */
94fd7f
 /*
94fd7f
  * Write out header information
94fd7f
  */
94fd7f
-fprintf (outfil, canned1);
94fd7f
+fprintf (outfil, "%s", canned1);
94fd7f
 fprintf (outfil, "%s\n", name);
94fd7f
-fprintf (outfil, canned2);
94fd7f
+fprintf (outfil, "%s", canned2);
94fd7f
 
94fd7f
 /*
94fd7f
  * Alphabetize the controls, reason, and argument lists
94fd7f
@@ -264,7 +264,7 @@ while ( ctlref != NULL )
94fd7f
 rsnndx = 0;
94fd7f
 ctlndx = 0;
94fd7f
 if ( mm_ctl_ptr->cnt == 0 )
94fd7f
-    fprintf (outfil, "No children are supported");
94fd7f
+    fprintf (outfil, "%s", "No children are supported");
94fd7f
 while ( rsnndx<mm_rsn_ptr->cnt || ctlndx<mm_ctl_ptr->cnt )
94fd7f
     {
94fd7f
     if ( ctlndx < mm_ctl_ptr->cnt )
94fd7f
@@ -275,7 +275,7 @@ while ( rsnndx<mm_rsn_ptr->cnt || ctlndx<mm_ctl_ptr->cnt )
94fd7f
 	ctlndx += 1;
94fd7f
 	}
94fd7f
     else
94fd7f
-	fprintf (outfil, "@");
94fd7f
+	fprintf (outfil, "%s", "@");
94fd7f
     
94fd7f
     if ( rsnndx < mm_rsn_ptr->cnt )
94fd7f
 	{
94fd7f
@@ -285,9 +285,9 @@ while ( rsnndx<mm_rsn_ptr->cnt || ctlndx<mm_ctl_ptr->cnt )
94fd7f
 	rsnndx += 1;
94fd7f
 	}
94fd7f
     else
94fd7f
-	fprintf (outfil, "\n");
94fd7f
+	fprintf (outfil, "%s", "\n");
94fd7f
     }
94fd7f
-fprintf (outfil, canned3);
94fd7f
+fprintf (outfil, "%s", canned3);
94fd7f
 
94fd7f
 /*
94fd7f
  * Write out the argument table
94fd7f
@@ -319,11 +319,11 @@ while ( argndx < mm_arg_ptr->cnt )
94fd7f
 			 argref->act_resource->syndef->dflt);
94fd7f
 	}
94fd7f
 	else
94fd7f
-	    fprintf (outfil, "  \n");
94fd7f
+	    fprintf (outfil, "%s", "  \n");
94fd7f
     }    
94fd7f
     argndx += 1;
94fd7f
     }
94fd7f
-fprintf (outfil, canned4);
94fd7f
+fprintf (outfil, "%s", canned4);
94fd7f
 
94fd7f
 }
94fd7f
 
94fd7f
diff --git a/tools/wml/wmlresolve.c b/tools/wml/wmlresolve.c
94fd7f
index 464ef29..3b8642c 100644
94fd7f
--- a/tools/wml/wmlresolve.c
94fd7f
+++ b/tools/wml/wmlresolve.c
94fd7f
@@ -1340,7 +1340,7 @@ for ( ndx=0 ; ndx<wml_obj_allclass_ptr->cnt ; ndx++ )
94fd7f
 /*
94fd7f
  * close the output file
94fd7f
  */
94fd7f
-fprintf (outfil, "\n\n");
94fd7f
+fprintf (outfil, "%s", "\n\n");
94fd7f
 printf ("\nCreated report file wml.report");
94fd7f
 fclose (outfil);
94fd7f
 
94fd7f
@@ -1369,14 +1369,14 @@ fprintf (outfil, "\n\n\nClass %s:", synobj->name);
94fd7f
 switch ( synobj->type )
94fd7f
     {
94fd7f
     case WmlClassTypeMetaclass:
94fd7f
-        fprintf (outfil, "\n  Type: Metaclass\t");
94fd7f
+        fprintf (outfil, "%s", "\n  Type: Metaclass\t");
94fd7f
 	if ( synobj->superclass != NULL )
94fd7f
 	    fprintf (outfil, "Superclass: %s\t", synobj->superclass);
94fd7f
 	if ( synobj->parentclass != NULL )
94fd7f
 	    fprintf (outfil, "Parentclass: %s\t", synobj->parentclass);
94fd7f
 	break;
94fd7f
     case WmlClassTypeWidget:
94fd7f
-	fprintf (outfil, "\n  Type: Widget\t");
94fd7f
+	fprintf (outfil, "%s", "\n  Type: Widget\t");
94fd7f
 	if ( synobj->superclass != NULL )
94fd7f
 	    fprintf (outfil, "Superclass: %s\t", synobj->superclass);
94fd7f
 	if ( synobj->parentclass != NULL )
94fd7f
@@ -1388,7 +1388,7 @@ switch ( synobj->type )
94fd7f
 	    fprintf (outfil, "Convenience function: %s", synobj->convfunc);
94fd7f
 	break;
94fd7f
     case WmlClassTypeGadget:
94fd7f
-	fprintf (outfil, "\n  Type: Gadget\t");
94fd7f
+	fprintf (outfil, "%s", "\n  Type: Gadget\t");
94fd7f
 	if ( synobj->superclass != NULL )
94fd7f
 	    fprintf (outfil, "Superclass: %s\t", synobj->superclass);
94fd7f
 	if ( synobj->parentclass != NULL )
94fd7f
@@ -1414,19 +1414,19 @@ if ( clsobj->nondialog != NULL )
94fd7f
  * is intended to match the way resources are printed in the toolkit manual,
94fd7f
  * so that checking is as easy as possible.
94fd7f
  */
94fd7f
-fprintf (outfil, "\n  Arguments:");
94fd7f
+fprintf (outfil, "%s", "\n  Arguments:");
94fd7f
 wmlResolvePrintClassArgs (outfil, clsobj);
94fd7f
 
94fd7f
 /*
94fd7f
  * Print the reasons valid in the class
94fd7f
  */
94fd7f
-fprintf (outfil, "\n  Reasons:");
94fd7f
+fprintf (outfil, "%s", "\n  Reasons:");
94fd7f
 wmlResolvePrintClassReasons (outfil, clsobj);
94fd7f
 
94fd7f
 /*
94fd7f
  * Print the controls valid in the class
94fd7f
  */
94fd7f
-fprintf (outfil, "\n  Controls:");
94fd7f
+fprintf (outfil, "%s", "\n  Controls:");
94fd7f
 for ( ndx=0 ; ndx<wml_obj_class_ptr->cnt ; ndx++ )
94fd7f
     {
94fd7f
     ctrlobj = (WmlClassDefPtr) wml_obj_class_ptr->hvec[ndx].objptr;
94fd7f
@@ -1512,10 +1512,10 @@ for ( ndx=0 ; ndx<wml_obj_arg_ptr->cnt ; ndx++ )
94fd7f
     switch ( resref->exclude )
94fd7f
 	{
94fd7f
 	case WmlAttributeTrue:
94fd7f
-	    fprintf (outfil, "\n\tExclude = True;");
94fd7f
+	    fprintf (outfil, "%s", "\n\tExclude = True;");
94fd7f
 	    break;
94fd7f
 	case WmlAttributeFalse:
94fd7f
-	    fprintf (outfil, "\n\tExclude = False;");
94fd7f
+	    fprintf (outfil, "%s", "\n\tExclude = False;");
94fd7f
 	    break;
94fd7f
 	}
94fd7f
     if ( resref->dflt != NULL )
94fd7f
@@ -1558,10 +1558,10 @@ if ( constr )
94fd7f
 	switch ( resref->exclude )
94fd7f
 	    {
94fd7f
 	    case WmlAttributeTrue:
94fd7f
-	        fprintf (outfil, "\n\tExclude = True;");
94fd7f
+	        fprintf (outfil, "%s", "\n\tExclude = True;");
94fd7f
 		break;
94fd7f
 	    case WmlAttributeFalse:
94fd7f
-		fprintf (outfil, "\n\tExclude = False;");
94fd7f
+		fprintf (outfil, "%s", "\n\tExclude = False;");
94fd7f
 		break;
94fd7f
 	    }
94fd7f
 	if ( resref->dflt != NULL )
94fd7f
@@ -1632,10 +1632,10 @@ for ( ndx=0 ; ndx<wml_obj_reason_ptr->cnt ; ndx++ )
94fd7f
     switch ( resref->exclude )
94fd7f
 	{
94fd7f
 	case WmlAttributeTrue:
94fd7f
-	    fprintf (outfil, "\n\tExclude = True;");
94fd7f
+	    fprintf (outfil, "%s", "\n\tExclude = True;");
94fd7f
 	    break;
94fd7f
 	case WmlAttributeFalse:
94fd7f
-	    fprintf (outfil, "\n\tExclude = False;");
94fd7f
+	    fprintf (outfil, "%s", "\n\tExclude = False;");
94fd7f
 	    break;
94fd7f
 	}
94fd7f
     resobj->ref_ptr = NULL;
94fd7f
-- 
94fd7f
2.13.0
94fd7f