aboutsummaryrefslogtreecommitdiff
path: root/gdb/procfs.c
diff options
context:
space:
mode:
authorMark Alexander <marka@cygnus>1999-01-29 02:19:27 +0000
committerMark Alexander <marka@cygnus>1999-01-29 02:19:27 +0000
commite5c9fdd2b656d306972283e197d1559245221b19 (patch)
treecc1072d048fde0a902be46c086dae76e279dcdf4 /gdb/procfs.c
parenta96acce3108f11454ecfe610d61ffb1fa93b2730 (diff)
downloadgdb-e5c9fdd2b656d306972283e197d1559245221b19.zip
gdb-e5c9fdd2b656d306972283e197d1559245221b19.tar.gz
gdb-e5c9fdd2b656d306972283e197d1559245221b19.tar.bz2
Fix for PR 17980:
* procfs.c (wait_fd): Handle deleted threads correctly.
Diffstat (limited to 'gdb/procfs.c')
-rw-r--r--gdb/procfs.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/gdb/procfs.c b/gdb/procfs.c
index eb4cbfb..cd1bbe5 100644
--- a/gdb/procfs.c
+++ b/gdb/procfs.c
@@ -970,8 +970,9 @@ wait_fd ()
printf_filtered ("LWP %d exited.\n",
(pi->pid >> 16) & 0xffff);
close_proc_file (pi);
+ i--; /* don't skip deleted entry */
if (num_fds != 0)
- continue; /* already another event to process */
+ break; /* already another event to process */
else
goto wait_again; /* wait for another event */
}