This is the mail archive of the gdb-patches@sourceware.org mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: XML XInclude support


On Thu, Feb 08, 2007 at 02:45:32PM +0100, Mark Kettenis wrote:
> > Could you try replacing that line with this, to avoid the % being
> > interpreted as a format specifier?
> > 
> > 	printf "'\''%c'\'', ", c
> 
> That seems to work, Thanks!

Oof - glad I checked; that's wrong.  I've committed this instead,
which should still work for you, but not leave binary gunk in the file.
%c interprets 'a' as a character but '0' as an ASCII code.

Ever feel like I accomplish nothing except breaking your builds? :-)

-- 
Daniel Jacobowitz
CodeSourcery

2007-02-08  Daniel Jacobowitz  <dan@codesourcery.com>

	* features/feature_to_c.sh: Use %s to avoid problems with nawk.

Index: gdb/features/feature_to_c.sh
===================================================================
RCS file: /cvs/src/src/gdb/features/feature_to_c.sh,v
retrieving revision 1.2
diff -u -p -r1.2 feature_to_c.sh
--- gdb/features/feature_to_c.sh	7 Feb 2007 22:48:06 -0000	1.2
+++ gdb/features/feature_to_c.sh	8 Feb 2007 13:55:08 -0000
@@ -51,7 +51,7 @@ for input; do
         } else if (c == "\\") {
           printf "'\''\\\\'\'', "
         } else if (_ord_[c] >= 32 && _ord_[c] < 127) {
-          printf "'\''" c "'\'', "
+	  printf "'\''%s'\'', ", c
         } else {
           printf "'\''\\%03o'\'', ", _ord_[c]
         }


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]