Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Menu
Open sidebar
Josh Wilcox
crown-core
Commits
d50fec5e
Commit
d50fec5e
authored
6 years ago
by
Ashot
Browse files
Options
Download
Email Patches
Plain Diff
Broadcast locked transactions
parent
7cb06024
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
src/instantx.cpp
+11
-0
src/instantx.cpp
src/net.cpp
+8
-0
src/net.cpp
src/net.h
+1
-0
src/net.h
with
20 additions
and
0 deletions
+20
-0
src/instantx.cpp
View file @
d50fec5e
...
...
@@ -160,6 +160,17 @@ void InstantSend::ProcessMessage(CNode* pfrom, const std::string& strCommand, CD
return
;
}
else
if
(
strCommand
==
"txllist"
)
//Get InstantX Locked list
{
std
::
map
<
uint256
,
CConsensusVote
>::
const_iterator
it
=
m_txLockVote
.
begin
();
for
(;
it
!=
m_txLockVote
.
end
();
++
it
)
{
CInv
inv
(
MSG_TXLOCK_VOTE
,
it
->
second
.
GetHash
());
pfrom
->
AddInventoryKnown
(
inv
);
RelayInv
(
inv
);
}
}
}
bool
InstantSend
::
IsIxTxValid
(
const
CTransaction
&
txCollateral
)
const
...
...
This diff is collapsed.
Click to expand it.
src/net.cpp
View file @
d50fec5e
...
...
@@ -467,6 +467,11 @@ void CNode::CloseSocketDisconnect()
vRecvMsg
.
clear
();
}
void
CNode
::
PushTxLockedList
()
{
PushMessage
(
"txllist"
);
}
void
CNode
::
PushVersion
()
{
int
nBestHeight
=
g_signals
.
GetHeight
().
get_value_or
(
0
);
...
...
@@ -2069,7 +2074,10 @@ CNode::CNode(SOCKET hSocketIn, CAddress addrIn, std::string addrNameIn, bool fIn
// Be shy and don't send version until we hear
if
(
hSocket
!=
INVALID_SOCKET
&&
!
fInbound
)
{
PushVersion
();
PushTxLockedList
();
}
GetNodeSignals
().
InitializeNode
(
GetId
(),
this
);
}
...
...
This diff is collapsed.
Click to expand it.
src/net.h
View file @
d50fec5e
...
...
@@ -422,6 +422,7 @@ public:
void
EndMessage
()
UNLOCK_FUNCTION
(
cs_vSend
);
void
PushVersion
();
void
PushTxLockedList
();
void
PushMessage
(
const
char
*
pszCommand
)
...
...
This diff is collapsed.
Click to expand it.
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment
Menu
Projects
Groups
Snippets
Help