Skip to content

Commit

Permalink
Merge pull request #4 from stream-labs/fix-critical-crash
Browse files Browse the repository at this point in the history
Check state of critical process when a crash happened
  • Loading branch information
eddyStreamlabs authored Mar 13, 2019
2 parents 8b7c37c + 0f69d2f commit 03dc52a
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion crash-handler-process/main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -211,7 +211,12 @@ void checkProcesses(std::mutex* m) {

if (!alive) {
index--;
if (!processes.at(index)->getCritical()) {
bool criticalProcessAlive = false;
for (size_t i = 0; i < processes.size(); i++) {
if (processes.at(i)->getCritical())
criticalProcessAlive = processes.at(i)->getAlive();
}
if (!processes.at(index)->getCritical() && criticalProcessAlive) {
int code = MessageBox(
NULL,
"An error occurred which has caused Streamlabs OBS to close. Don't worry! If you were streaming or recording, that is still happening in the background."
Expand Down

0 comments on commit 03dc52a

Please sign in to comment.