Skip to content
This repository was archived by the owner on May 31, 2022. It is now read-only.

Commit 7c82223

Browse files
author
Allen Webster
committed
fix crash when closing cli output buffer
1 parent 1eff9ea commit 7c82223

File tree

1 file changed

+10
-0
lines changed

1 file changed

+10
-0
lines changed

4ed_api_implementation.cpp

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -920,6 +920,16 @@ buffer_kill(Application_Links *app, Buffer_ID buffer_id, Buffer_Kill_Flag flags)
920920
}
921921
}
922922

923+
Child_Process_Container *child_processes = &models->child_processes;
924+
for (Node *node = child_processes->child_process_active_list.next;
925+
node != &child_processes->child_process_active_list;
926+
node = node->next){
927+
Child_Process *child_process = CastFromMember(Child_Process, node, node);
928+
if (child_process->out_file == file){
929+
child_process->out_file = 0;
930+
}
931+
}
932+
923933
result = BufferKillResult_Killed;
924934
}
925935
else{

0 commit comments

Comments
 (0)