Bug 204945

Summary: usr/src/usr.sbin/acpi/acpidump/acpi.c:729: code relies on undefined behaviour ?
Product: Base System Reporter: David Binderman <dcb314>
Component: miscAssignee: freebsd-acpi (Nobody) <acpi>
Status: New ---    
Severity: Affects Some People    
Priority: ---    
Version: CURRENT   
Hardware: Any   
OS: Any   

Description David Binderman 2015-12-01 19:40:44 UTC
[usr/src/usr.sbin/acpi/acpidump/acpi.c:729]: (warning) Invalid test for overflow 'vaddr+sizeof(struct TCPAevent)<vaddr'. Condition is always false unless there is overflow, and overflow is Undefined Behaviour.

Source code is

        if ((vaddr + sizeof(struct TCPAevent) >= vend)||
            (vaddr + sizeof(struct TCPAevent) < vaddr))
            break;