Skip to content

Commit df18635

Browse files
committed
Let MAC choose address when mesh forwarding
We accidentally copied the source address form (16- or 64-bit) when forwarding a mesh packet, so if the incoming packet had a 64-bit source, we used a 64-bit source. Clear the address type field before selecting address, so we use the default behaviour of "use 16-bit if available". This means we will use 16-bit in Thread - eliminates our involvement in the case of one vendor rejecting mesh packets with 64-bit MAC source. Change-Id: I77b925cd6efd43095c5fc8c00a63abda5f908ffa
1 parent 42f916b commit df18635

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

source/6LoWPAN/Mesh/mesh.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -243,6 +243,7 @@ buffer_t *mesh_up(buffer_t *buf)
243243
memcpy(buf->dst_sa.address + 2, route.address, route.addr_len);
244244

245245
/* Set src MAC address from our interface */
246+
buf->src_sa.addr_type = ADDR_NONE;
246247
if (!mac_helper_write_our_addr(cur, &buf->src_sa)) {
247248
goto drop;
248249
}

0 commit comments

Comments
 (0)