|
From: Madhan S. <mad...@gm...> - 2009-11-24 09:37:14
|
Hello,
An ampersand (&) character when found in the command line arguments of
an application,
is not encoded into an xml safe form (&) when xml output is enabled.
The same characters are encoded properly in the "args" section,
but appear as-is in the "preample" section.
Please refer to the xml snippet below for an example.
This causes a parse failure with standard xml parsers.
Thanks,
Madhan.
<preamble>
<line>Memcheck, a memory error detector</line>
<line>Copyright (C) 2002-2009, and GNU GPL'd, by Julian Seward et al.</line>
<line>Using Valgrind-3.5.0 and LibVEX; rerun with -h for copyright info</line>
<line>Command: ./a && & \></line>
</preamble>
<pid>5546</pid>
<ppid>15439</ppid>
<tool>memcheck</tool>
<args>
<vargv>
<exe>/usr/local/bin/valgrind</exe>
<arg>--xml=yes</arg>
<arg>--xml-file=abc</arg>
</vargv>
<argv>
<exe>./a</exe>
<arg>&&</arg>
<arg>&</arg>
<arg>></arg>
</argv>
</args>
|
|
From: Julian S. <js...@ac...> - 2009-11-24 09:47:08
|
Easy enough to fix. Can you send a small test program and commands to show the problem, so I can test the fix? J On Tuesday 24 November 2009, Madhan Sadasivam wrote: > Hello, > > An ampersand (&) character when found in the command line arguments of > an application, > is not encoded into an xml safe form (&) when xml output is enabled. > > The same characters are encoded properly in the "args" section, > but appear as-is in the "preample" section. > > Please refer to the xml snippet below for an example. > This causes a parse failure with standard xml parsers. > > Thanks, > Madhan. > > > <preamble> > <line>Memcheck, a memory error detector</line> > <line>Copyright (C) 2002-2009, and GNU GPL'd, by Julian Seward et > al.</line> <line>Using Valgrind-3.5.0 and LibVEX; rerun with -h for > copyright info</line> <line>Command: ./a && & \></line> > </preamble> > > <pid>5546</pid> > <ppid>15439</ppid> > <tool>memcheck</tool> > > <args> > <vargv> > <exe>/usr/local/bin/valgrind</exe> > <arg>--xml=yes</arg> > <arg>--xml-file=abc</arg> > </vargv> > <argv> > <exe>./a</exe> > <arg>&&</arg> > <arg>&</arg> > <arg>></arg> > </argv> > </args> > > --------------------------------------------------------------------------- >--- Let Crystal Reports handle the reporting - Free Crystal Reports 2008 > 30-Day trial. Simplify your report design, integration and deployment - and > focus on what you do best, core application coding. Discover what's new > with Crystal Reports now. http://p.sf.net/sfu/bobj-july > _______________________________________________ > Valgrind-users mailing list > Val...@li... > https://lists.sourceforge.net/lists/listinfo/valgrind-users |
|
From: Madhan S. <mad...@gm...> - 2009-11-26 05:51:25
|
Thanks Julian, the following is the testcase. valgrind --xml=yes --xml-file=ls.xml ls '&' '>' Thanks, Madhan. On Tue, Nov 24, 2009 at 3:30 PM, Julian Seward <js...@ac...> wrote: > > Easy enough to fix. Can you send a small test program and commands to > show the problem, so I can test the fix? > > J > > On Tuesday 24 November 2009, Madhan Sadasivam wrote: >> Hello, >> >> An ampersand (&) character when found in the command line arguments of >> an application, >> is not encoded into an xml safe form (&) when xml output is enabled. >> >> The same characters are encoded properly in the "args" section, >> but appear as-is in the "preample" section. >> >> Please refer to the xml snippet below for an example. >> This causes a parse failure with standard xml parsers. >> >> Thanks, >> Madhan. >> >> >> <preamble> >> <line>Memcheck, a memory error detector</line> >> <line>Copyright (C) 2002-2009, and GNU GPL'd, by Julian Seward et >> al.</line> <line>Using Valgrind-3.5.0 and LibVEX; rerun with -h for >> copyright info</line> <line>Command: ./a && & \></line> >> </preamble> >> >> <pid>5546</pid> >> <ppid>15439</ppid> >> <tool>memcheck</tool> >> >> <args> >> <vargv> >> <exe>/usr/local/bin/valgrind</exe> >> <arg>--xml=yes</arg> >> <arg>--xml-file=abc</arg> >> </vargv> >> <argv> >> <exe>./a</exe> >> <arg>&&</arg> >> <arg>&</arg> >> <arg>></arg> >> </argv> >> </args> >> >> --------------------------------------------------------------------------- >>--- Let Crystal Reports handle the reporting - Free Crystal Reports 2008 >> 30-Day trial. Simplify your report design, integration and deployment - and >> focus on what you do best, core application coding. Discover what's new >> with Crystal Reports now. http://p.sf.net/sfu/bobj-july >> _______________________________________________ >> Valgrind-users mailing list >> Val...@li... >> https://lists.sourceforge.net/lists/listinfo/valgrind-users > > > |
|
From: Madhan S. <mad...@gm...> - 2009-12-10 17:08:49
|
Hope that helped ! I also came across cases where special characters present in command line arguments appear as-is in <args><argv><arg> and <preamble><line> content. These characters also breaks standard xml parsers. The testcase is the following: valgrind --xml=yes --xml-file=ls.xml ls ^C^A^D Where ^C is input by using the key combination ctrl+v followed by ctrl+C and so on. I guess this would constitude binary data and hence should be dumped using the xml's CDATA tags. The appearance of such characters are rare but its not surprising to see them in regression tests. As with the earlier case, these are found in Valgrind 3.5.0. Thanks, Madhan. On Thu, Nov 26, 2009 at 11:21 AM, Madhan Sadasivam <mad...@gm...> wrote: > Thanks Julian, the following is the testcase. > > valgrind --xml=yes --xml-file=ls.xml ls '&' '>' > > Thanks, > Madhan. > > On Tue, Nov 24, 2009 at 3:30 PM, Julian Seward <js...@ac...> wrote: >> >> Easy enough to fix. Can you send a small test program and commands to >> show the problem, so I can test the fix? >> >> J >> >> On Tuesday 24 November 2009, Madhan Sadasivam wrote: >>> Hello, >>> >>> An ampersand (&) character when found in the command line arguments of >>> an application, >>> is not encoded into an xml safe form (&) when xml output is enabled. >>> >>> The same characters are encoded properly in the "args" section, >>> but appear as-is in the "preample" section. >>> >>> Please refer to the xml snippet below for an example. >>> This causes a parse failure with standard xml parsers. >>> >>> Thanks, >>> Madhan. >>> >>> >>> <preamble> >>> <line>Memcheck, a memory error detector</line> >>> <line>Copyright (C) 2002-2009, and GNU GPL'd, by Julian Seward et >>> al.</line> <line>Using Valgrind-3.5.0 and LibVEX; rerun with -h for >>> copyright info</line> <line>Command: ./a && & \></line> >>> </preamble> >>> >>> <pid>5546</pid> >>> <ppid>15439</ppid> >>> <tool>memcheck</tool> >>> >>> <args> >>> <vargv> >>> <exe>/usr/local/bin/valgrind</exe> >>> <arg>--xml=yes</arg> >>> <arg>--xml-file=abc</arg> >>> </vargv> >>> <argv> >>> <exe>./a</exe> >>> <arg>&&</arg> >>> <arg>&</arg> >>> <arg>></arg> >>> </argv> >>> </args> >>> >>> --------------------------------------------------------------------------- >>>--- Let Crystal Reports handle the reporting - Free Crystal Reports 2008 >>> 30-Day trial. Simplify your report design, integration and deployment - and >>> focus on what you do best, core application coding. Discover what's new >>> with Crystal Reports now. http://p.sf.net/sfu/bobj-july >>> _______________________________________________ >>> Valgrind-users mailing list >>> Val...@li... >>> https://lists.sourceforge.net/lists/listinfo/valgrind-users >> >> >> > |
|
From: Madhan S. <mad...@gm...> - 2009-12-10 17:37:44
|
Please let me get back to you on this one, the problem is only with special characters appearing in <preamble><line> but not in <args><argv><arg>. I will check it and will let you know. Madhan. On Thu, Dec 10, 2009 at 10:38 PM, Madhan Sadasivam <mad...@gm...> wrote: > Hope that helped ! > > I also came across cases where special characters present in command > line arguments > appear as-is in <args><argv><arg> and <preamble><line> content. > These characters also breaks standard xml parsers. > > The testcase is the following: > valgrind --xml=yes --xml-file=ls.xml ls ^C^A^D > > Where ^C is input by using the key combination ctrl+v followed by > ctrl+C and so on. > > I guess this would constitude binary data and hence should be dumped using > the xml's CDATA tags. The appearance of such characters are rare but its > not surprising to see them in regression tests. > > As with the earlier case, these are found in Valgrind 3.5.0. > > Thanks, > Madhan. > > On Thu, Nov 26, 2009 at 11:21 AM, Madhan Sadasivam > <mad...@gm...> wrote: >> Thanks Julian, the following is the testcase. >> >> valgrind --xml=yes --xml-file=ls.xml ls '&' '>' >> >> Thanks, >> Madhan. >> >> On Tue, Nov 24, 2009 at 3:30 PM, Julian Seward <js...@ac...> wrote: >>> >>> Easy enough to fix. Can you send a small test program and commands to >>> show the problem, so I can test the fix? >>> >>> J >>> >>> On Tuesday 24 November 2009, Madhan Sadasivam wrote: >>>> Hello, >>>> >>>> An ampersand (&) character when found in the command line arguments of >>>> an application, >>>> is not encoded into an xml safe form (&) when xml output is enabled. >>>> >>>> The same characters are encoded properly in the "args" section, >>>> but appear as-is in the "preample" section. >>>> >>>> Please refer to the xml snippet below for an example. >>>> This causes a parse failure with standard xml parsers. >>>> >>>> Thanks, >>>> Madhan. >>>> >>>> >>>> <preamble> >>>> <line>Memcheck, a memory error detector</line> >>>> <line>Copyright (C) 2002-2009, and GNU GPL'd, by Julian Seward et >>>> al.</line> <line>Using Valgrind-3.5.0 and LibVEX; rerun with -h for >>>> copyright info</line> <line>Command: ./a && & \></line> >>>> </preamble> >>>> >>>> <pid>5546</pid> >>>> <ppid>15439</ppid> >>>> <tool>memcheck</tool> >>>> >>>> <args> >>>> <vargv> >>>> <exe>/usr/local/bin/valgrind</exe> >>>> <arg>--xml=yes</arg> >>>> <arg>--xml-file=abc</arg> >>>> </vargv> >>>> <argv> >>>> <exe>./a</exe> >>>> <arg>&&</arg> >>>> <arg>&</arg> >>>> <arg>></arg> >>>> </argv> >>>> </args> >>>> >>>> --------------------------------------------------------------------------- >>>>--- Let Crystal Reports handle the reporting - Free Crystal Reports 2008 >>>> 30-Day trial. Simplify your report design, integration and deployment - and >>>> focus on what you do best, core application coding. Discover what's new >>>> with Crystal Reports now. http://p.sf.net/sfu/bobj-july >>>> _______________________________________________ >>>> Valgrind-users mailing list >>>> Val...@li... >>>> https://lists.sourceforge.net/lists/listinfo/valgrind-users >>> >>> >>> >> > |