-
Notifications
You must be signed in to change notification settings - Fork 1.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Refactor All The Things - part1 #928
Conversation
@@ -1,4 +1,3 @@ | |||
|
|||
// Copyright (c) 2009-2012 The Dash Core developers |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nit: Copyright (c) 2014-2016 The Dash Core developers
utACK 9bc414c - love it ❤️ Shall we squash for merge or keep it as is? |
@schinzelh nit addressed. I'm fine with either way, I separated them only to make review easier :) |
Ooops, forgot to include |
LOVE it ❤️ Much easier to read and understand now. 100% utACK |
After merging #911 this needs a rebase now :) |
+ move strMasterNodeAddr to CActiveMasternode
+ new lock cs_instantsend to protect maps on CleanTransactionLocksList() + new DEFAULT_INSTANTSEND_DEPTH constant + rename MIN_INSTANTX_PROTO_VERSION to MIN_INSTANTSEND_PROTO_VERSION and bump it
+ decouple from util.h and version.h + more functions for CDarksendBroadcastTx: constructors, signing, serialization + move from rand() to insecure_rand() in general but to GetRand() for session id + fix defaults
utACK d24182c |
lol, holy crap udjin 👍 I need a bit of time to review this, but I'll get to it soon :D |
Alright... Time to clean up my diff backlog :)
I apologize in advance for a somewhat huge PR but things are way too interconnected here and also changes are mostly trivial. I tried to break it into 3 more or less separated commits though, so hopefully this will help to make review a bit easier. Also would like to mention that this is the first part of it and there is more to come in following PRs but I need this as a base (together with #911), so please don't put it at the end of your review queue :D
In general all of this is simply trying to:
CActiveMasternode
strMasterNodeAddr
out of util.h toCActiveMasternode
cs_instantsend
to protect maps onCleanTransactionLocksList()
DEFAULT_INSTANTSEND_DEPTH
constantMIN_INSTANTX_PROTO_VERSION
toMIN_INSTANTSEND_PROTO_VERSION
and bump itfEnableInstantSend
andnInstantSendDepth
out of util.hCConsensusVote::GetHash()
currently works i.e. it doesn't return a hash at all.CDarksendBroadcastTx
: constructors, signing, serializationinsecure_rand()
instead of rand() in general butGetRand()
for session idDEFAULT_...
nPrivateSendRounds
,nPrivateSendAmount
,nLiquidityProvider
,fEnablePrivateSend
,fPrivateSendMultiSession
,darkSendDenominations
out of util.hNote:
vin
part of some names was changed totxin
(which is a proper name for an object ofCTxIn
becausevin
stands for vector ofCTxIn
s) where applicable but not everywhere. That's intentional, I'll explain this in (one of?) the next part :)