aboutsummaryrefslogtreecommitdiff
path: root/src/protocol.h
diff options
context:
space:
mode:
authorSuhas Daftuar <sdaftuar@gmail.com>2020-01-30 10:10:50 -0500
committerSuhas Daftuar <sdaftuar@gmail.com>2020-07-19 02:10:41 -0400
commit46d78d47dea345329ba094310eec56ab00a02ddc (patch)
treebb811d9a5512988a7824f6d11c12ed508677b796 /src/protocol.h
parent2d282e0cba9761574b6b43d134ca95f3052d7fd2 (diff)
downloadbitcoin-46d78d47dea345329ba094310eec56ab00a02ddc.tar.xz
Add p2p message "wtxidrelay"
When sent to and received from a given peer, enables using wtxid's for announcing and fetching transactions with that peer.
Diffstat (limited to 'src/protocol.h')
-rw-r--r--src/protocol.h8
1 files changed, 7 insertions, 1 deletions
diff --git a/src/protocol.h b/src/protocol.h
index 2c68a97c00..d83da2034a 100644
--- a/src/protocol.h
+++ b/src/protocol.h
@@ -261,6 +261,12 @@ extern const char* GETCFCHECKPT;
* evenly spaced filter headers for blocks on the requested chain.
*/
extern const char* CFCHECKPT;
+/**
+ * Indicates that a node prefers to relay transactions via wtxid, rather than
+ * txid.
+ * @since protocol version 70016 as described by BIP 339.
+ */
+extern const char *WTXIDRELAY;
}; // namespace NetMsgType
/* Get a vector of all valid message types (see above) */
@@ -402,7 +408,7 @@ enum GetDataMsg : uint32_t {
MSG_TX = 1,
MSG_BLOCK = 2,
MSG_WTX = 5, //!< Defined in BIP 339
- // The following can only occur in getdata. Invs always use TX or BLOCK.
+ // The following can only occur in getdata. Invs always use TX/WTX or BLOCK.
MSG_FILTERED_BLOCK = 3, //!< Defined in BIP37
MSG_CMPCT_BLOCK = 4, //!< Defined in BIP152
MSG_WITNESS_BLOCK = MSG_BLOCK | MSG_WITNESS_FLAG, //!< Defined in BIP144