anchao opened a new pull request, #7789:
URL: https://github.com/apache/nuttx/pull/7789

   ## Summary
   
   1. net/icmpv6: fix UBSan warning
   
   ```
   ubsan_prologue: 
================================================================================
   ubsan_prologue: UBSAN: misaligned-access in icmpv6/icmpv6_radvertise.c:147:21
   handle_misaligned_access: member access within misaligned address 0x56bbc362 
for type 'struct icmpv6_router_advertise_s'
   handle_misaligned_access: which requires 4 byte alignment
   ubsan_epilogue: 
================================================================================
   ubsan_prologue: 
================================================================================
   ubsan_prologue: UBSAN: misaligned-access in icmpv6/icmpv6_radvertise.c:169:21
   handle_misaligned_access: member access within misaligned address 0x56bbc37a 
for type 'struct icmpv6_mtu_s'
   handle_misaligned_access: which requires 4 byte alignment
   ubsan_epilogue: 
================================================================================
   ubsan_prologue: 
================================================================================
   ubsan_prologue: UBSAN: misaligned-access in icmpv6/icmpv6_radvertise.c:178:23
   handle_misaligned_access: member access within misaligned address 0x56bbc382 
for type 'struct icmpv6_prefixinfo_s'
   handle_misaligned_access: which requires 4 byte alignment
   ubsan_epilogue: 
================================================================================
   ubsan_prologue: 
================================================================================
   ubsan_prologue: UBSAN: misaligned-access in icmpv6/icmpv6_radvertise.c:204:16
   handle_misaligned_access: member access within misaligned address 0x56bbc362 
for type 'struct icmpv6_router_advertise_s'
   handle_misaligned_access: which requires 4 byte alignment
   ubsan_epilogue: 
================================================================================
   
   ```
   2. net/icmpv6: fix compile warning
   
   ```
   icmpv6/icmpv6_input.c: In function ‘icmpv6_input’:
   icmpv6/icmpv6_input.c:342:46: warning: taking address of packed member of 
‘struct icmpv6_prefixinfo_s’
                                          may result in an unaligned pointer 
value [-Waddress-of-packed-member]
     342 |                                     prefixopt->prefix, 
prefixopt->preflen);
         |
   ```
   
   3. compile/attribute: minor fix for packed struct mismatch
   
   
   
   Signed-off-by: chao an <anc...@xiaomi.com>
   
   
   ## Impact
   
   N/A
   
   ## Testing
   
   ci check


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org

Reply via email to