• Sven Eckelmann's avatar
    batman-adv: Check type of x and y in seq_(before|after) · 0bb85751
    Sven Eckelmann authored
    seq_before and seq_after depend on the fact that both sequence numbers
    have the same type and thus the same bitwidth. We can ensure that by
    compile time checking using a compare between the pointer to the
    temporary buffers which were created using the typeof of both
    parameters. For example gcc would create a warning like
    "warning: comparison of distinct pointer types lacks a cast".
    Signed-off-by: default avatarSven Eckelmann <sven@narfation.org>
    0bb85751
main.h 6.12 KB