From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 18818 invoked by alias); 27 Oct 2010 08:21:09 -0000 Received: (qmail 18804 invoked by uid 22791); 27 Oct 2010 08:21:07 -0000 X-SWARE-Spam-Status: No, hits=-1.8 required=5.0 tests=AWL,BAYES_00,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,FREEMAIL_FROM,RCVD_IN_DNSWL_NONE X-Spam-Check-By: sourceware.org Received: from mail-ww0-f43.google.com (HELO mail-ww0-f43.google.com) (74.125.82.43) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Wed, 27 Oct 2010 08:21:02 +0000 Received: by wwb39 with SMTP id 39so368259wwb.12 for ; Wed, 27 Oct 2010 01:21:00 -0700 (PDT) Received: by 10.216.15.10 with SMTP id e10mr476029wee.21.1288167660242; Wed, 27 Oct 2010 01:21:00 -0700 (PDT) MIME-Version: 1.0 Received: by 10.216.182.139 with HTTP; Wed, 27 Oct 2010 01:20:39 -0700 (PDT) In-Reply-To: References: From: Hui Zhu Date: Wed, 27 Oct 2010 08:21:00 -0000 Message-ID: Subject: [PATCH] tracepoint.c: fix the bug that S use utp->actions in trace_save To: gdb-patches ml Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable X-IsSubscribed: yes Mailing-List: contact gdb-patches-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sourceware.org X-SW-Source: 2010-10/txt/msg00379.txt.bz2 Ping. ---------- Forwarded message ---------- From: Hui Zhu Date: Fri, Oct 22, 2010 at 13:12 Subject: [PATCH] tracepoint.c: fix the bug that S use utp->actions in trace= _save To: gdb-patches ml Hi, I found that in the tracepoint.c:trace_save(tsave will call this function) generate a part S to save the action message: =A0 =A0 =A0for (a =3D 0; VEC_iterate (char_ptr, utp->actions, a, act); ++a) =A0 =A0 =A0 =A0fprintf (fp, "tp S%x:%s:%s\n", =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 utp->number, phex_nz (utp->addr, sizeof (ut= p->addr)), act); But it same with the A part: =A0 =A0 =A0for (a =3D 0; VEC_iterate (char_ptr, utp->actions, a, act); ++a) =A0 =A0 =A0 =A0fprintf (fp, "tp A%x:%s:%s\n", =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 utp->number, phex_nz (utp->addr, sizeof (ut= p->addr)), act); I think the S should use step_actions. So I make a patch for it. Thanks, Hui 2010-10-22 =A0Hui Zhu =A0 =A0 =A0 =A0 =A0* tracepoint.c (trace_save): Change utp->actions to =A0 =A0 =A0 =A0utp->step_actions. --- =A0tracepoint.c | =A0 =A02 +- =A01 file changed, 1 insertion(+), 1 deletion(-) --- a/tracepoint.c +++ b/tracepoint.c @@ -2734,7 +2734,7 @@ trace_save (const char *filename, int ta =A0 =A0 =A0 for (a =3D 0; VEC_iterate (char_ptr, utp->actions, a, act); ++a) =A0 =A0 =A0 =A0fprintf (fp, "tp A%x:%s:%s\n", =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 utp->number, phex_nz (utp->addr, sizeof (ut= p->addr)), act); - =A0 =A0 =A0for (a =3D 0; VEC_iterate (char_ptr, utp->actions, a, act); ++= a) + =A0 =A0 =A0for (a =3D 0; VEC_iterate (char_ptr, utp->step_actions, a, act= ); ++a) =A0 =A0 =A0 =A0fprintf (fp, "tp S%x:%s:%s\n", =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 utp->number, phex_nz (utp->addr, sizeof (ut= p->addr)), act); =A0 =A0 =A0 if (utp->at_string)