+2005-11-11 Kevin Buettner <kevinb@redhat.com>
+
+ * lwp-pool.c (clear_all_do_step_flags): New function.
+ (lwp_pool_singlestep_lwp): Use it.
+
2005-11-10 Kevin Buettner <kevinb@redhat.com>
* lwp-pool.c (mark_lwp_as_dead_but_interesting): New function.
}
+/* Clear the `do_step' flags for all LWPs in the hash table. */
+
+static void
+clear_all_do_step_flags (void)
+{
+ int i;
+
+ for (i = 0; i < hash_size; i++)
+ {
+ struct lwp *l = hash[i];
+
+ if (l)
+ l->do_step = 0;
+ }
+}
+
+
int
lwp_pool_singlestep_lwp (struct gdbserv *serv, pid_t lwp, int signal)
{
fprintf (stderr, "lwp_pool_singlestep_lwp (%p, %d, %d)\n",
serv, (int) lwp, signal);
+ /* Neither GDB nor the software singlestep code contained in RDA
+ expect more than one LWP to be stepped simultaneously. Clear the
+ `do_step' flag in all LWPs. The flag for the LWP that we're about
+ to step will be set later on. */
+ clear_all_do_step_flags ();
+
switch (l->state)
{
case lwp_state_uninitialized: