You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@mynewt.apache.org by gi...@git.apache.org on 2017/10/10 14:27:29 UTC

[GitHub] jhedberg commented on a change in pull request #609: Mesh improvements

jhedberg commented on a change in pull request #609: Mesh improvements
URL: https://github.com/apache/mynewt-core/pull/609#discussion_r143744385
 
 

 ##########
 File path: net/nimble/host/mesh/src/cfg.c
 ##########
 @@ -1742,11 +1742,11 @@ static void mod_sub_va_overwrite(struct bt_mesh_model *model,
 	elem_addr = net_buf_simple_pull_le16(buf);
 	label_uuid = buf->om_data;
 	net_buf_simple_pull(buf, 16);
-
-	BT_DBG("elem_addr 0x%04x", elem_addr);
-
 	mod_id = buf->om_data;
 
+	BT_DBG("elem_addr 0x%04x, addr %s, mod_id 0x%x", elem_addr,
+	       bt_hex(label_uuid, 16), bt_hex(mod_id, buf->om_len));
 
 Review comment:
   It seems the mod_id gets printed in the wrong endianess here. The access/model layer is little endian, but the first byte after '0x' should be the most significant one. If you don't want to bother with conversions and dealing with the two possible lengths, you could just omit the 0x and have a dump of the raw bytes, I suppose.
 
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services