diff options
Diffstat (limited to 'gdb/windows-nat.c')
-rw-r--r-- | gdb/windows-nat.c | 15 |
1 files changed, 7 insertions, 8 deletions
diff --git a/gdb/windows-nat.c b/gdb/windows-nat.c index b577fdb55f8..04b745eb608 100644 --- a/gdb/windows-nat.c +++ b/gdb/windows-nat.c @@ -330,7 +330,7 @@ struct windows_nat_target : public x86_nat_target<inf_child_target> void mourn_inferior () OVERRIDE; - int thread_alive (ptid_t ptid) OVERRIDE; + bool thread_alive (ptid_t ptid) OVERRIDE; char *pid_to_str (ptid_t) OVERRIDE; @@ -340,7 +340,7 @@ struct windows_nat_target : public x86_nat_target<inf_child_target> ptid_t get_ada_task_ptid (long lwp, long thread) OVERRIDE; - int get_tib_address (ptid_t ptid, CORE_ADDR *addr) OVERRIDE; + bool get_tib_address (ptid_t ptid, CORE_ADDR *addr) OVERRIDE; const char *thread_name (struct thread_info *) OVERRIDE; }; @@ -2597,19 +2597,19 @@ windows_nat_target::xfer_partial (enum target_object object, /* Provide thread local base, i.e. Thread Information Block address. Returns 1 if ptid is found and sets *ADDR to thread_local_base. */ -int +bool windows_nat_target::get_tib_address (ptid_t ptid, CORE_ADDR *addr) { windows_thread_info *th; th = thread_rec (ptid_get_tid (ptid), 0); if (th == NULL) - return 0; + return false; if (addr != NULL) *addr = th->thread_local_base; - return 1; + return true; } ptid_t @@ -2785,7 +2785,7 @@ cygwin_get_dr7 (void) by "polling" it. If WaitForSingleObject returns WAIT_OBJECT_0 it means that the thread has died. Otherwise it is assumed to be alive. */ -int +bool windows_nat_target::thread_alive (ptid_t ptid) { int tid; @@ -2793,8 +2793,7 @@ windows_nat_target::thread_alive (ptid_t ptid) gdb_assert (ptid_get_tid (ptid) != 0); tid = ptid_get_tid (ptid); - return WaitForSingleObject (thread_rec (tid, FALSE)->h, 0) == WAIT_OBJECT_0 - ? FALSE : TRUE; + return WaitForSingleObject (thread_rec (tid, FALSE)->h, 0) != WAIT_OBJECT_0; } /* -Wmissing-prototypes */ |