Move GetTempPath() to testutil#7667
Merged
laanwj merged 2 commits intobitcoin:masterfrom Mar 14, 2016
Merged
Conversation
Contributor
|
Nice! |
3a87cd5 to
2fdaa25
Compare
Contributor
Author
|
Fixed Windows build error. The build passes now. |
Contributor
|
ACK |
Member
|
utACK 2fdaa25 |
Member
|
Yes, makes sense, utACK 2fdaa25 |
laanwj
added a commit
that referenced
this pull request
Mar 14, 2016
zkbot
added a commit
to zcash/zcash
that referenced
this pull request
Oct 26, 2020
Lightweight abstraction of boost::filesystem This is a refactor backport ahead of replacing most of our Boost dependencies with C++17 code. Cherry-picked from the following upstream PRs: - bitcoin/bitcoin#7667 - Removes merge conflicts. - bitcoin/bitcoin#9902 - bitcoin/bitcoin@2300a5e - bitcoin/bitcoin#10546 - Only the changes to `src/fs.cpp`
This file contains hidden or 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
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Addresses #6702 and #6701.
This pull request creates a new source file for test utils, and moves GetTempPath() from util to testutil.
This is because per the above issues, GetTempPath() is insecure and has unchecked error conditions, making it unsuitable for use in production code. GetTempPath() is only used in the unit tests and not used anywhere in the main code, so it would be a good idea to move this to the test suite so that no one tries to use this in the future and it's not mixed with production code.