Skip to content

Commit 3dc4607

Browse files
author
Scott Powell
committed
* PAYLOAD_TYPE_PATH: reserving upper 4 bits if 'extra_type' field, for future use
1 parent a72fafc commit 3dc4607

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/Mesh.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -135,7 +135,7 @@ DispatcherAction Mesh::onRecvPacket(Packet* pkt) {
135135
int k = 0;
136136
uint8_t path_len = data[k++];
137137
uint8_t* path = &data[k]; k += path_len;
138-
uint8_t extra_type = data[k++];
138+
uint8_t extra_type = data[k++] & 0x0F; // upper 4 bits reserved for future use
139139
uint8_t* extra = &data[k];
140140
uint8_t extra_len = len - k; // remainder of packet (may be padded with zeroes!)
141141
if (onPeerPathRecv(pkt, j, secret, path, path_len, extra_type, extra, extra_len)) {

0 commit comments

Comments
 (0)