Skip to content

Make sure pwalletMain is not null whenever it's used in PS client - #2190

Merged
UdjinM6 merged 2 commits into
dashpay:developfrom
UdjinM6:notNullWalletInPS
Jul 28, 2018
Merged

Make sure pwalletMain is not null whenever it's used in PS client#2190
UdjinM6 merged 2 commits into
dashpay:developfrom
UdjinM6:notNullWalletInPS

Conversation

@UdjinM6

@UdjinM6 UdjinM6 commented Jul 20, 2018

Copy link
Copy Markdown

Fixes another crash when wallet is shutdown right after the start and makes code a bit safer in general :)

@UdjinM6 UdjinM6 added this to the 12.4 milestone Jul 20, 2018
@UdjinM6 UdjinM6 added the bug label Jul 21, 2018
{
if(fMasternodeMode) return false; // no client-side mixing on masternodes
if(!fEnablePrivateSend) return false;
if(!pwalletMain || pwalletMain->IsLocked(true)) return false;

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Condition pwalletMain->IsLocked(true) is not checked in new code. Is it OK?

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ooops. This is ok but it's from another fix. Will revert here.

@gladcow gladcow left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

utACK

@nmarley nmarley left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

utACK

@UdjinM6
UdjinM6 merged commit 30fa8bc into dashpay:develop Jul 28, 2018
CryptoCentric pushed a commit to absolute-community/absolute that referenced this pull request Apr 25, 2019
…shpay#2190)

* Make sure pwalletMain is not null whenever it's used in PS client

* partially revert
@UdjinM6
UdjinM6 deleted the notNullWalletInPS branch November 26, 2020 13:27
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants