summaryrefslogtreecommitdiff
path: root/gdb/thread.c
diff options
context:
space:
mode:
authorMichael Snyder <msnyder@specifix.com>2011-01-11 21:53:23 +0000
committerMichael Snyder <msnyder@specifix.com>2011-01-11 21:53:23 +0000
commit499de1b6987b0d26b03ac25e06ad41dbc64f5f26 (patch)
treebd9707729be1a1c2dea86aa8afbbd2c4581fcaf9 /gdb/thread.c
parent1be1f93a991dd0172debb6f6f5371b82fd3e950c (diff)
downloadgdb-499de1b6987b0d26b03ac25e06ad41dbc64f5f26.tar.gz
2011-01-11 Michael Snyder <msnyder@vmware.com>
* s390-tdep.c: Comment cleanup, mostly periods and spaces. * score-tdep.c: Ditto. * score-tdep.h: Ditto. * ser-base.c: Ditto. * ser-go32.c: Ditto. * serial.c: Ditto. * serial.h: Ditto. * ser-mingw.c: Ditto. * ser-pipe.c: Ditto. * ser-tcp.c: Ditto. * ser-unix.c: Ditto. * sh64-tdep.c: Ditto. * shnbsd-nat.c: Ditto. * sh-tdep.c: Ditto. * sh-tdep.h: Ditto. * solib.c: Ditto. * solib-darwin.c: Ditto. * solib-frv.c: Ditto. * solib.h: Ditto. * solib-irix.c: Ditto. * solib-osf.c: Ditto. * solib-pa64.c: Ditto. * solib-som.c: Ditto. * solib-spu.c: Ditto. * solib-sunos.c: Ditto. * solib-svr4.c: Ditto. * solist.h: Ditto. * sol-thread.c: Ditto. * somread.c: Ditto. * source.c: Ditto. * source.h: Ditto. * sparc64-linux-tdep.c: Ditto. * sparc64-tdep.c: Ditto. * sparc-linux-nat.c: Ditto. * sparc-linux-tdep.c: Ditto. * sparc-sol2-nat.c: Ditto. * sparc-sol2-tdep.c: Ditto. * sparc-tdep.c: Ditto. * sparc-tdep.h: Ditto. * spu-tdep.c: Ditto. * stabsread.c: Ditto. * stabsread.h: Ditto. * stack.c: Ditto. * symfile.c: Ditto. * symfile.h: Ditto. * symmisc.c: Ditto. * symtab.c: Ditto. * symtab.h: Ditto. * target.c: Ditto. * target-descriptions.c: Ditto. * target-descriptions.h: Ditto. * target.h: Ditto. * target-memory.c: Ditto. * terminal.h: Ditto. * thread.c: Ditto. * top.c: Ditto. * tracepoint.c: Ditto. * tracepoint.h: Ditto. * trad-frame.h: Ditto. * typeprint.c: Ditto.
Diffstat (limited to 'gdb/thread.c')
-rw-r--r--gdb/thread.c31
1 files changed, 15 insertions, 16 deletions
diff --git a/gdb/thread.c b/gdb/thread.c
index 99b4a9348bd..d35a2a665f1 100644
--- a/gdb/thread.c
+++ b/gdb/thread.c
@@ -44,13 +44,13 @@
#include "annotate.h"
#include "cli/cli-decode.h"
-/* Definition of struct thread_info exported to gdbthread.h */
+/* Definition of struct thread_info exported to gdbthread.h. */
-/* Prototypes for exported functions. */
+/* Prototypes for exported functions. */
void _initialize_thread (void);
-/* Prototypes for local functions. */
+/* Prototypes for local functions. */
static struct thread_info *thread_list = NULL;
static int highest_thread_num;
@@ -432,7 +432,7 @@ in_thread_list (ptid_t ptid)
if (ptid_equal (tp->ptid, ptid))
return 1;
- return 0; /* Never heard of 'im */
+ return 0; /* Never heard of 'im. */
}
/* Finds the first thread of the inferior given by PID. If PID is -1,
@@ -482,7 +482,7 @@ any_live_thread_of_process (int pid)
}
/* Print a list of thread ids currently known, and the total number of
- threads. To be used from within catch_errors. */
+ threads. To be used from within catch_errors. */
static int
do_captured_list_thread_ids (struct ui_out *uiout, void *arg)
{
@@ -516,7 +516,7 @@ do_captured_list_thread_ids (struct ui_out *uiout, void *arg)
}
/* Official gdblib interface function to get a list of thread ids and
- the total number. */
+ the total number. */
enum gdb_rc
gdb_list_thread_ids (struct ui_out *uiout, char **error_message)
{
@@ -526,7 +526,7 @@ gdb_list_thread_ids (struct ui_out *uiout, char **error_message)
return GDB_RC_OK;
}
-/* Return true if TP is an active thread. */
+/* Return true if TP is an active thread. */
static int
thread_alive (struct thread_info *tp)
{
@@ -754,12 +754,12 @@ finish_thread_state_cleanup (void *arg)
/* Prints the list of threads and their details on UIOUT.
This is a version of 'info_thread_command' suitable for
- use from MI.
+ use from MI.
If REQUESTED_THREAD is not -1, it's the GDB id of the thread
that should be printed. Otherwise, all threads are
- printed.
+ printed.
If PID is not -1, only print threads from the process PID.
- Otherwise, threads from all attached PIDs are printed.
+ Otherwise, threads from all attached PIDs are printed.
If both REQUESTED_THREAD and PID are not -1, then the thread
is printed if it belongs to the specified process. Otherwise,
an error is raised. */
@@ -940,7 +940,7 @@ info_threads_command (char *arg, int from_tty)
print_thread_info (uiout, -1, -1);
}
-/* Switch from one thread to another. */
+/* Switch from one thread to another. */
void
switch_to_thread (ptid_t ptid)
@@ -1128,8 +1128,7 @@ make_cleanup_restore_current_thread (void)
thread apply 1 2 7 4 backtrace Apply backtrace cmd to threads 1,2,7,4
thread apply 2-7 9 p foo(1) Apply p foo(1) cmd to threads 2->7 & 9
- thread apply all p x/i $pc Apply x/i $pc cmd to all threads
- */
+ thread apply all p x/i $pc Apply x/i $pc cmd to all threads. */
static void
thread_apply_all_command (char *cmd, int from_tty)
@@ -1146,7 +1145,7 @@ thread_apply_all_command (char *cmd, int from_tty)
old_chain = make_cleanup_restore_current_thread ();
/* Save a copy of the command in case it is clobbered by
- execute_command */
+ execute_command. */
saved_cmd = xstrdup (cmd);
make_cleanup (xfree, saved_cmd);
for (tp = thread_list; tp; tp = tp->next)
@@ -1181,7 +1180,7 @@ thread_apply_command (char *tidlist, int from_tty)
error (_("Please specify a command following the thread ID list"));
/* Save a copy of the command in case it is clobbered by
- execute_command */
+ execute_command. */
saved_cmd = xstrdup (cmd);
old_chain = make_cleanup (xfree, saved_cmd);
while (tidlist < cmd)
@@ -1197,7 +1196,7 @@ thread_apply_command (char *tidlist, int from_tty)
while (*tidlist == ' ' || *tidlist == '\t')
tidlist++;
- if (*tidlist == '-') /* Got a range of IDs? */
+ if (*tidlist == '-') /* Got a range of IDs? */
{
tidlist++; /* Skip the - */
end = strtol (tidlist, &p, 10);