Re: [PATCH net] selftests/net: in timestamping, strncpy needs to preserve null byte

2020-06-08 Thread David Miller
From: Tanner Love Date: Mon, 8 Jun 2020 15:37:15 -0400 > From: tannerlove > > If user passed an interface option longer than 15 characters, then > device.ifr_name and hwtstamp.ifr_name became non-null-terminated > strings. The compiler warned about this: > > timestamping.c:353:2: warning: ‘st

[PATCH net] selftests/net: in timestamping, strncpy needs to preserve null byte

2020-06-08 Thread Tanner Love
From: tannerlove If user passed an interface option longer than 15 characters, then device.ifr_name and hwtstamp.ifr_name became non-null-terminated strings. The compiler warned about this: timestamping.c:353:2: warning: ‘strncpy’ specified bound 16 equals \ destination size [-Wstringop-truncati