mirror of
https://github.com/linux-can/can-utils.git
synced 2026-09-20 23:12:09 +02:00
Consistent arguments to sizeof().
In calls to functions taking a pointer 'p' and a length 'l': if a struct variable v is passed in for p, then also pass sizeof(v) for l.
This commit is contained in:
@@ -305,7 +305,7 @@ int main(int argc, char *argv[])
|
||||
}
|
||||
|
||||
/* Configure baud rate */
|
||||
memset(&tios, 0, sizeof(struct termios));
|
||||
memset(&tios, 0, sizeof(tios));
|
||||
if (tcgetattr(fd, &tios) < 0) {
|
||||
syslogger(LOG_NOTICE, "failed to get attributes for TTY device %s: %s\n", ttypath, strerror(errno));
|
||||
exit(EXIT_FAILURE);
|
||||
|
||||
Reference in New Issue
Block a user