Hi,

Today I noticed findutils contains several debugging messages that 
are gettextized.  In my opinion this is unnecessary: normal users 
won't be using the program compiled with DEBUG defined, so they 
will never see these messages.  Also, several other debugging 
messages in for example find.c and plural.c are not gettextized 
either.  Attached patch undoes the gettextization of the remaining 
debugging messages.

Regards,

Benno
diff -ur cvs-findutils/find/find.c findutils/find/find.c
--- cvs-findutils/find/find.c	2005-04-10 15:06:34.000000000 +0200
+++ findutils/find/find.c	2005-05-08 16:21:18.000000000 +0200
@@ -284,7 +284,7 @@
 
   options.symlink_handling = opt;
   
-  /* For DBEUG_STAT, the choice is made at runtime within debug_stat()
+  /* For DEBUG_STAT, the choice is made at runtime within debug_stat()
    * by checking the contents of the symlink_handling variable.
    */
 #if defined(DEBUG_STAT)
@@ -552,7 +552,7 @@
     }
 
 #ifdef	DEBUG
-  fprintf (stderr, _("Predicate List:\n"));
+  fprintf (stderr, "Predicate List:\n");
   print_list (stderr, predicates);
 #endif /* DEBUG */
 
@@ -569,7 +569,7 @@
     }
   
 #ifdef	DEBUG
-  fprintf (stderr, _("Eval Tree:\n"));
+  fprintf (stderr, "Eval Tree:\n");
   print_tree (stderr, eval_tree, 0);
 #endif /* DEBUG */
 
@@ -582,9 +582,9 @@
   mark_type (eval_tree);
 
 #ifdef DEBUG
-  fprintf (stderr, _("Optimized Eval Tree:\n"));
+  fprintf (stderr, "Optimized Eval Tree:\n");
   print_tree (stderr, eval_tree, 0);
-  fprintf (stderr, _("Optimized command line:\n"));
+  fprintf (stderr, "Optimized command line:\n");
   print_optlist(stderr, eval_tree);
   fprintf(stderr, "\n");
 #endif /* DEBUG */
diff -ur cvs-findutils/find/parser.c findutils/find/parser.c
--- cvs-findutils/find/parser.c	2005-05-08 15:28:14.000000000 +0200
+++ findutils/find/parser.c	2005-05-08 16:10:05.000000000 +0200
@@ -2239,8 +2239,8 @@
   our_pred->args.info.l_val = t;
   (*arg_ptr)++;
 #ifdef	DEBUG
-  fprintf (stderr, _("inserting %s\n"), our_pred->p_name);
-  fprintf (stderr, _("    type: %s    %s  "),
+  fprintf (stderr, "inserting %s\n", our_pred->p_name);
+  fprintf (stderr, "    type: %s    %s  ",
 	  (c_type == COMP_GT) ? "gt" :
 	  ((c_type == COMP_LT) ? "lt" : ((c_type == COMP_EQ) ? "eq" : "?")),
 	  (c_type == COMP_GT) ? " >" :
@@ -2250,8 +2250,7 @@
   if (c_type == COMP_EQ)
     {
       t = our_pred->args.info.l_val += DAYSECS;
-      fprintf (stderr,
-	       "                 <  %ju %s",
+      fprintf (stderr, "                 <  %ju %s",
 	      (uintmax_t) our_pred->args.info.l_val, ctime (&t));
       our_pred->args.info.l_val -= DAYSECS;
     }
@@ -2320,8 +2319,8 @@
   our_pred->args.info.l_val = num;
   (*arg_ptr)++;
 #ifdef	DEBUG
-  fprintf (stderr, _("inserting %s\n"), our_pred->p_name);
-  fprintf (stderr, _("    type: %s    %s  "),
+  fprintf (stderr, "inserting %s\n", our_pred->p_name);
+  fprintf (stderr, "    type: %s    %s  ",
 	  (c_type == COMP_GT) ? "gt" :
 	  ((c_type == COMP_LT) ? "lt" : ((c_type == COMP_EQ) ? "eq" : "?")),
 	  (c_type == COMP_GT) ? " >" :
diff -ur cvs-findutils/find/pred.c findutils/find/pred.c
--- cvs-findutils/find/pred.c	2005-03-14 10:53:44.000000000 +0100
+++ findutils/find/pred.c	2005-05-08 16:10:05.000000000 +0200
@@ -1687,11 +1687,11 @@
   
   for (i = 0; i < indent; i++)
     fprintf (fp, "    ");
-  fprintf (fp, _("left:\n"));
+  fprintf (fp, "left:\n");
   print_tree (fp, node->pred_left, indent + 1);
   for (i = 0; i < indent; i++)
     fprintf (fp, "    ");
-  fprintf (fp, _("right:\n"));
+  fprintf (fp, "right:\n");
   print_tree (fp, node->pred_right, indent + 1);
 }
 
@@ -1776,8 +1776,8 @@
       print_parenthesised(fp, p->pred_left);
       fprintf (fp,
 	       "%s%s%s ",
-	       p->need_stat ? _("[stat called here] ") : "",
-	       p->need_type ? _("[type needed here] ") : "",
+	       p->need_stat ? "[stat called here] " : "",
+	       p->need_type ? "[type needed here] " : "",
 	       blank_rtrim (find_pred_name (p->pred_func), name));
       print_parenthesised(fp, p->pred_right);
     }
diff -ur cvs-findutils/find/tree.c findutils/find/tree.c
--- cvs-findutils/find/tree.c	2005-02-09 22:57:33.000000000 +0100
+++ findutils/find/tree.c	2005-05-08 16:10:05.000000000 +0200
@@ -242,7 +242,7 @@
   
 #ifdef DEBUG
   /* Normalized tree. */
-  fprintf (stderr, _("Normalized Eval Tree:\n"));
+  fprintf (stderr, "Normalized Eval Tree:\n");
   print_tree (stderr, *eval_treep, 0);
 #endif
 
_______________________________________________
Bug-findutils mailing list
Bug-findutils@gnu.org
http://lists.gnu.org/mailman/listinfo/bug-findutils

Reply via email to