summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authoroharboe <oharboe@b42882b7-edfa-0310-969c-e2dbd0fdcd60>2009-09-29 14:23:42 +0000
committeroharboe <oharboe@b42882b7-edfa-0310-969c-e2dbd0fdcd60>2009-09-29 14:23:42 +0000
commit035b6ba84b3180b6432810605d7fc4ee98aea650 (patch)
treeb47ac727fc88ca3743f195bbf3532d7bd4920b62 /src
parent9bdbffb8cc0d169349b5580b42602268e773b470 (diff)
downloadopenocd+libswd-035b6ba84b3180b6432810605d7fc4ee98aea650.tar.gz
openocd+libswd-035b6ba84b3180b6432810605d7fc4ee98aea650.tar.bz2
openocd+libswd-035b6ba84b3180b6432810605d7fc4ee98aea650.tar.xz
openocd+libswd-035b6ba84b3180b6432810605d7fc4ee98aea650.zip
reentry assert
git-svn-id: svn://svn.berlios.de/openocd/trunk@2770 b42882b7-edfa-0310-969c-e2dbd0fdcd60
Diffstat (limited to 'src')
-rw-r--r--src/jtag/driver.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/src/jtag/driver.c b/src/jtag/driver.c
index 14ae163e..3bce5d57 100644
--- a/src/jtag/driver.c
+++ b/src/jtag/driver.c
@@ -489,6 +489,11 @@ void interface_jtag_add_callback4(jtag_callback_t callback, jtag_callback_data_t
int interface_jtag_execute_queue(void)
{
+ static int reentry = 0;
+
+ assert(reentry==0);
+ reentry++;
+
int retval = default_interface_jtag_execute_queue();
if (retval == ERROR_OK)
{
@@ -504,6 +509,8 @@ int interface_jtag_execute_queue(void)
jtag_command_queue_reset();
jtag_callback_queue_reset();
+ reentry--;
+
return retval;
}