Andy Shevchenko 21f585480d fbtft: Make sure string is NULL terminated
New GCC warns about inappropriate use of strncpy():

drivers/staging/fbtft/fbtft-core.c: In function ‘fbtft_framebuffer_alloc’:
drivers/staging/fbtft/fbtft-core.c:665:2: warning: ‘strncpy’ specified bound 16 equals destination size [-Wstringop-truncation]
  665 |  strncpy(info->fix.id, dev->driver->name, 16);
      |  ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Later on the copy is being used with the assumption to be NULL terminated.
Make sure string is NULL terminated by switching to snprintf().

Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Link: https://lore.kernel.org/r/20191120095716.26628-1-andriy.shevchenko@linux.intel.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-11-20 14:35:57 +01:00
..
2019-11-01 09:30:48 -07:00
2019-10-23 06:26:33 -04:00
2019-09-19 14:14:28 -07:00
2019-09-18 11:14:31 -07:00
2019-09-22 12:02:21 -07:00
2019-11-11 06:23:37 +01:00
2019-08-27 09:43:59 +02:00
2019-10-25 14:25:15 +02:00
2019-10-18 22:29:36 -04:00
2019-11-06 21:48:29 -08:00
2019-09-23 17:20:40 -04:00
2019-09-29 10:33:41 -07:00
2019-11-08 18:15:55 -08:00
2019-10-15 23:51:36 +02:00
2019-09-23 19:16:01 -07:00
2019-11-11 06:23:37 +01:00
2019-10-23 15:31:17 -04:00
2019-09-22 10:55:08 -07:00
2019-09-22 11:05:43 -07:00
2019-10-22 17:55:51 +02:00
2019-11-02 11:15:52 -07:00
2019-10-26 19:47:31 +08:00
2019-09-17 18:40:42 -07:00
2019-11-02 11:15:52 -07:00
2019-09-18 11:14:31 -07:00
2019-10-15 14:07:01 -06:00
2019-09-18 11:05:34 -07:00