Skip to content

Commit

Permalink
Fix detected leaks/heap-use-after-free by AddressSanitizer at startup
Browse files Browse the repository at this point in the history
(cherry picked from commit 3f94ea6)
  • Loading branch information
Rubonnek authored and akien-mga committed Mar 13, 2022
1 parent c594e1c commit 0ae6150
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions platform/x11/detect_prime.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -175,7 +175,7 @@ int detect_prime() {
close(fdset[0]);

} else {
// In child, exit() here will not quit the engine.
// In child, killing this process will not quit the engine.

char string[201];

Expand Down Expand Up @@ -203,7 +203,7 @@ int detect_prime() {
print_verbose("Couldn't write vendor/renderer string.");
}
close(fdset[1]);
exit(0);
raise(SIGINT);
}
}

Expand Down

0 comments on commit 0ae6150

Please sign in to comment.