Fix for PR 17980:
authorMark Alexander <marka@cygnus>
Fri, 29 Jan 1999 02:19:27 +0000 (02:19 +0000)
committerMark Alexander <marka@cygnus>
Fri, 29 Jan 1999 02:19:27 +0000 (02:19 +0000)
* procfs.c (wait_fd): Handle deleted threads correctly.

gdb/ChangeLog
gdb/procfs.c

index d3c9e5f247720574b28f8dac63313ec9ac5c60f0..667b24b4e1738215e199ef269a6f88a853b4d1ca 100644 (file)
@@ -1,3 +1,7 @@
+Thu Jan 28 18:16:07 1999  Mark Alexander  <marka@cygnus.com>
+
+       * procfs.c (wait_fd): Handle deleted threads correctly.
+
 1999-01-28  Jason Molenda  (jsm@bugshack.cygnus.com)
 
        * utils.c (init_page_info): Force window size if running under emacs.
index eb4cbfbf032d30238ffeea562fc1fd5da11d06ea..cd1bbe5b67e3669a3064d8a81ca33a004ee53573 100644 (file)
@@ -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 */
                }