aboutsummaryrefslogtreecommitdiffstats
path: root/src/w32proc.c
diff options
context:
space:
mode:
authorGlenn Morris2012-12-21 11:32:43 -0800
committerGlenn Morris2012-12-21 11:32:43 -0800
commita4b0cca119b01dc55bad802ef696c857fe014482 (patch)
treef2df86b3d472d15d3bbb69274325a7c0090f65b3 /src/w32proc.c
parent0e9c7693712014196946a83709a83c08a7dfea25 (diff)
parent160b3852018831b830a7451f29f770fb49810342 (diff)
downloademacs-a4b0cca119b01dc55bad802ef696c857fe014482.tar.gz
emacs-a4b0cca119b01dc55bad802ef696c857fe014482.zip
Merge from emacs-24; up to 2012-12-01T13:25:13Z!cyd@gnu.org
Diffstat (limited to 'src/w32proc.c')
-rw-r--r--src/w32proc.c10
1 files changed, 6 insertions, 4 deletions
diff --git a/src/w32proc.c b/src/w32proc.c
index 43ecf4d68f3..1693b2ad501 100644
--- a/src/w32proc.c
+++ b/src/w32proc.c
@@ -800,7 +800,7 @@ new_child (void)
800 DWORD id; 800 DWORD id;
801 801
802 for (cp = child_procs + (child_proc_count-1); cp >= child_procs; cp--) 802 for (cp = child_procs + (child_proc_count-1); cp >= child_procs; cp--)
803 if (!CHILD_ACTIVE (cp)) 803 if (!CHILD_ACTIVE (cp) && cp->procinfo.hProcess == NULL)
804 goto Initialize; 804 goto Initialize;
805 if (child_proc_count == MAX_CHILDREN) 805 if (child_proc_count == MAX_CHILDREN)
806 return NULL; 806 return NULL;
@@ -859,7 +859,7 @@ delete_child (child_process *cp)
859 if (fd_info[i].cp == cp) 859 if (fd_info[i].cp == cp)
860 emacs_abort (); 860 emacs_abort ();
861 861
862 if (!CHILD_ACTIVE (cp)) 862 if (!CHILD_ACTIVE (cp) && cp->procinfo.hProcess == NULL)
863 return; 863 return;
864 864
865 /* Delete the child's temporary input file, if any, that is pending 865 /* Delete the child's temporary input file, if any, that is pending
@@ -918,7 +918,8 @@ delete_child (child_process *cp)
918 if (cp == child_procs + child_proc_count - 1) 918 if (cp == child_procs + child_proc_count - 1)
919 { 919 {
920 for (i = child_proc_count-1; i >= 0; i--) 920 for (i = child_proc_count-1; i >= 0; i--)
921 if (CHILD_ACTIVE (&child_procs[i])) 921 if (CHILD_ACTIVE (&child_procs[i])
922 || child_procs[i].procinfo.hProcess != NULL)
922 { 923 {
923 child_proc_count = i + 1; 924 child_proc_count = i + 1;
924 break; 925 break;
@@ -935,7 +936,8 @@ find_child_pid (DWORD pid)
935 child_process *cp; 936 child_process *cp;
936 937
937 for (cp = child_procs + (child_proc_count-1); cp >= child_procs; cp--) 938 for (cp = child_procs + (child_proc_count-1); cp >= child_procs; cp--)
938 if (CHILD_ACTIVE (cp) && pid == cp->pid) 939 if ((CHILD_ACTIVE (cp) || cp->procinfo.hProcess != NULL)
940 && pid == cp->pid)
939 return cp; 941 return cp;
940 return NULL; 942 return NULL;
941} 943}