-
Notifications
You must be signed in to change notification settings - Fork 745
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add a
Symbolizer::GetEnvP()
method that allows symbolizer implement…
…ations to customise the environment of the symbolizer binary. Summary: This change introduces the `Symbolizer::GetEnvP()` method that returns a pointer to environment array used for spawning the symbolizer process. The motivation is to allow implementations to customise the environment if required. The default implementation just returns `__sanitizer::GetEnviron()` which (provided it's implemented) should preserve the existing behaviours of the various implementations. This change has been plumbed through the `internal_spawn(...)` and `StartSubprocess(...)` process spawning implementations. For the `StartSubprocess()` implementation we need to call `execve()` rather than `execv()` to pass the environment. However, it appears that `internal_execve(...)` exists in sanitizer_common so this patch use that which seems like a nice clean up. Support in the Windows implementation of `SymbolizerProcess:StartSymbolizerSubprocess()` has not been added because the Windows sanitizer runtime doesn't implement `GetEnviron()`. rdar://problem/58789439 Reviewers: kubamracek, yln, dvyukov, vitalybuka, eugenis, phosek, aizatsky, rnk Subscribers: #sanitizers, llvm-commits Tags: #sanitizers Differential Revision: https://reviews.llvm.org/D76666
- Loading branch information
Showing
8 changed files
with
20 additions
and
14 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters