summaryrefslogtreecommitdiff
path: root/src/target
diff options
context:
space:
mode:
authoroharboe <oharboe@b42882b7-edfa-0310-969c-e2dbd0fdcd60>2008-10-07 17:45:26 +0000
committeroharboe <oharboe@b42882b7-edfa-0310-969c-e2dbd0fdcd60>2008-10-07 17:45:26 +0000
commit2babd879165466517b3d5f0530794a3885b3eeaf (patch)
treeeeea3b322b106bf630774e56d44ac19b56a42e93 /src/target
parente8e59951601da48f254f068916f8034cb6a20924 (diff)
downloadopenocd+libswd-2babd879165466517b3d5f0530794a3885b3eeaf.tar.gz
openocd+libswd-2babd879165466517b3d5f0530794a3885b3eeaf.tar.bz2
openocd+libswd-2babd879165466517b3d5f0530794a3885b3eeaf.tar.xz
openocd+libswd-2babd879165466517b3d5f0530794a3885b3eeaf.zip
Frederik Kriewitz <frederik at kriewitz.eu> Segmentation fault fix.
git-svn-id: svn://svn.berlios.de/openocd/trunk@1025 b42882b7-edfa-0310-969c-e2dbd0fdcd60
Diffstat (limited to 'src/target')
-rw-r--r--src/target/trace.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/target/trace.c b/src/target/trace.c
index ee894f18..257e8ceb 100644
--- a/src/target/trace.c
+++ b/src/target/trace.c
@@ -75,7 +75,10 @@ int handle_trace_point_command(struct command_context_s *cmd_ctx, char *cmd, cha
if (!strcmp(args[0], "clear"))
{
if (trace->trace_points)
+ {
free(trace->trace_points);
+ trace->trace_points = NULL;
+ }
trace->num_trace_points = 0;
trace->trace_points_size = 0;