hwmon: (ntc_thermistor) Ensure that data->name string is terminated
Fix Coverity warning: Calling strncpy with a maximum size argument of 20 bytes on destination array "data->name" of size 20 bytes might leave the destination string unterminated. Fix by replacing strncpy() with strlcpy() and by using sizeof() to determine the maximum string length. Signed-off-by: NGuenter Roeck <linux@roeck-us.net> Acked-by: NJean Delvare <khali@linux-fr.org>
Showing
想要评论请 注册 或 登录