Linux: -Wvarargs in drivers/net/can/usb/peak_usb/pcan_usb_pro.c

Created on 18 Sep 2018  路  4Comments  路  Source: ClangBuiltLinux/linux

drivers/net/can/usb/peak_usb/pcan_usb_pro.c:136:15: warning: passing an object that undergoes default argument promotion to 'va_start' has undefined behavior [-Wvarargs]
        va_start(ap, id);
                     ^
drivers/net/can/usb/peak_usb/pcan_usb_pro.c:130:61: note: parameter of type 'u8' (aka 'unsigned char') is declared here
static int pcan_msg_add_rec(struct pcan_usb_pro_msg *pm, u8 id, ...)
                                                            ^
1 warning generated.
-Wvarargs [BUG] linux [FIXED][LINUX] 5.1

Most helpful comment

All 4 comments

Note: similar to #41 (probably need to declare id as an int): https://www.eskimo.com/~scs/cclass/int/sx11c.html

Was this page helpful?
0 / 5 - 0 ratings

Related issues

nickdesaulniers picture nickdesaulniers  路  4Comments

nathanchance picture nathanchance  路  3Comments

tpgxyz picture tpgxyz  路  4Comments

nickdesaulniers picture nickdesaulniers  路  3Comments

nickdesaulniers picture nickdesaulniers  路  5Comments