Skip to content

Conversation

@laanwj
Copy link
Member

@laanwj laanwj commented Jul 25, 2017

This assures that we don't overwrite a random file called wallet.backup that happens to be in the current directory. It also assures that the temporary file will be cleaned up.

Noticed by Evan Klitzke, came up in discussion here: #10880 (comment)

This assures that we don't overwrite a random file called
`wallet.backup` that happens to be in the current directory. It also
assures that the temporary file will be cleaned up.

Noticed by Evan Klitzke, came up in discussion here:
bitcoin#10880 (comment)
@laanwj laanwj added the Tests label Jul 25, 2017
@jonasschnelli
Copy link
Contributor

utACK 88af227

@promag
Copy link
Contributor

promag commented Jul 25, 2017

utACK 88af227.

@practicalswift
Copy link
Contributor

utACK 88af227

Excerpt from the boost::filesystem::path documentation for some context:

The append operations use operator/= to denote their semantic effect of appending the platform's preferred directory separator when needed.

@TheBlueMatt
Copy link
Contributor

utACK

@maflcko
Copy link
Member

maflcko commented Jul 25, 2017

Thanks! utACK 88af227

@laanwj laanwj merged commit 88af227 into bitcoin:master Jul 25, 2017
laanwj added a commit that referenced this pull request Jul 25, 2017
88af227 test: Make sure wallet.backup is created in temp path (Wladimir J. van der Laan)

Pull request description:

  This assures that we don't overwrite a random file called `wallet.backup` that happens to be in the current directory. It also assures that the temporary file will be cleaned up.

  Noticed by Evan Klitzke, came up in discussion here: #10880 (comment)

Tree-SHA512: 2d2c23c2deba26a1130a29279b3d8565b277eb90a98a6a6d7dd4948f5cbbd5ec5453b3082e3e4e21e0e2423e642bbd2f4433e4c21032d3c8cff27ee35e87e7e7
PastaPastaPasta pushed a commit to PastaPastaPasta/dash that referenced this pull request Aug 2, 2019
… path

88af227 test: Make sure wallet.backup is created in temp path (Wladimir J. van der Laan)

Pull request description:

  This assures that we don't overwrite a random file called `wallet.backup` that happens to be in the current directory. It also assures that the temporary file will be cleaned up.

  Noticed by Evan Klitzke, came up in discussion here: bitcoin#10880 (comment)

Tree-SHA512: 2d2c23c2deba26a1130a29279b3d8565b277eb90a98a6a6d7dd4948f5cbbd5ec5453b3082e3e4e21e0e2423e642bbd2f4433e4c21032d3c8cff27ee35e87e7e7
@bitcoin bitcoin locked as resolved and limited conversation to collaborators Sep 8, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants