* tracepoint.c (parse_trace_status): Don't allow plain strings in
	the terror description.  Don't expect an X prefix.

	gdb/doc/
	* gdb.texinfo (Tracepoint Packets): Remove mention that
	terror:string may be plain text, and drop mention of X prefix.
This commit is contained in:
Pedro Alves 2010-03-26 13:35:06 +00:00
parent ddfd679590
commit 99b5e152aa
4 changed files with 14 additions and 16 deletions

View File

@ -1,3 +1,8 @@
2010-03-26 Pedro Alves <pedro@codesourcery.com>
* tracepoint.c (parse_trace_status): Don't allow plain strings in
the terror description. Don't expect an X prefix.
2010-03-25 Stan Shebs <stan@codesourcery.com>
* tracepoint.h (trace_stop_reason): Add tracepoint_error.

View File

@ -1,3 +1,8 @@
2010-03-26 Pedro Alves <pedro@codesourcery.com>
* gdb.texinfo (Tracepoint Packets): Remove mention that
terror:string may be plain text, and drop mention of X prefix.
2010-03-26 Vladimir Prus <vladimir@codesourcery.com>
* gdb.texinfo (GDB/MI Tracepoint Commands): Add comma after @xref.

View File

@ -31366,10 +31366,7 @@ The trace stopped because tracepoint @var{tpnum} exceeded its pass count.
The trace stopped because tracepoint @var{tpnum} had an error. The
string @var{text} is available to describe the nature of the error
(for instance, a divide by zero in the condition expression).
@var{text} may take either of two forms; it may be plain text, but
with the restriction that no colons or other special characters are
allowed, or it may be an @code{X} followed by hex digits encoding the
text string.
@var{text} is hex encoded.
@item tunknown:0
The trace stopped for some other reason.

View File

@ -3197,18 +3197,9 @@ Status line: '%s'\n"), p, line);
if (p2 != p1)
{
int end;
ts->error_desc = (char *) xmalloc (p2 - p1 + 1);
/* See if we're doing plain text or hex encoding. */
if (*p1 == 'X')
{
++p1;
end = hex2bin (p1, ts->error_desc, (p2 - p1) / 2);
}
else
{
memcpy (ts->error_desc, p1, p2 - p1);
end = p2 - p1;
}
ts->error_desc = xmalloc ((p2 - p1) / 2 + 1);
end = hex2bin (p1, ts->error_desc, (p2 - p1) / 2);
ts->error_desc[end] = '\0';
}
p = unpack_varlen_hex (++p2, &val);