Another find.
When any client start it ask at least 3 other nodes for full MN list https://github.com/darkcoin/darkcoin/blob/master/src/darksend.cpp#L1978
and get them by dsee messages https://github.com/darkcoin/darkcoin/blob/master/src/masternode.cpp#L260
While first response will pass this loop https://github.com/darkcoin/darkcoin/blob/master/src/masternode.cpp#L90
without entering there and will keep lastTimeSeen equal to received lastUpdated https://github.com/darkcoin/darkcoin/blob/master/src/masternode.cpp#L141
next responses from other 2+ nodes will go inside loop and override lastTimeSeen with current time https://github.com/darkcoin/darkcoin/blob/master/src/masternode.cpp#L95
giving every masternode another 70 minutes of "life" on this particular client. So when someone else will start his client and connect to this client to get MN list he will refresh time for every masternode in his own list again.
I think MNs could "drift" quite a while by this feature
Solution:
modify this line https://github.com/darkcoin/darkcoin/blob/master/src/masternode.cpp#L95
to
and/or
move it inside next "if" https://github.com/darkcoin/darkcoin/blob/master/src/masternode.cpp#L97
EDIT: http://jira.darkcoin.qa/browse/DRK-126
When any client start it ask at least 3 other nodes for full MN list https://github.com/darkcoin/darkcoin/blob/master/src/darksend.cpp#L1978
and get them by dsee messages https://github.com/darkcoin/darkcoin/blob/master/src/masternode.cpp#L260
While first response will pass this loop https://github.com/darkcoin/darkcoin/blob/master/src/masternode.cpp#L90
without entering there and will keep lastTimeSeen equal to received lastUpdated https://github.com/darkcoin/darkcoin/blob/master/src/masternode.cpp#L141
next responses from other 2+ nodes will go inside loop and override lastTimeSeen with current time https://github.com/darkcoin/darkcoin/blob/master/src/masternode.cpp#L95
giving every masternode another 70 minutes of "life" on this particular client. So when someone else will start his client and connect to this client to get MN list he will refresh time for every masternode in his own list again.
I think MNs could "drift" quite a while by this feature
Solution:
modify this line https://github.com/darkcoin/darkcoin/blob/master/src/masternode.cpp#L95
to
Code:
mn.UpdateLastSeen(lastUpdated);
move it inside next "if" https://github.com/darkcoin/darkcoin/blob/master/src/masternode.cpp#L97
EDIT: http://jira.darkcoin.qa/browse/DRK-126
Last edited by a moderator: